Description
There's a check in pip.bzl that requires that each pip hub have a call with the default python version. This should be removed because a child doesn't necessarily need anything setup for the default python version. If it uses the version-aware rules, then it won't be affected by what the default is.
While it's likely the child module isn't using the version-aware rules, we don't know one-way or the other during extension execution. So we'll just have to assume the MODULE author knows what they're doing. The failure mode in this case is dependencies will be resolved for e.g. Python 3.9, but at runtime, the targets will use e.g. Python 3.10. 🤷 oh well.
edit: I think there's a second problem, too: a child module doesn't have a way to satisfy both the "one call per python version" check and "default python version must be setup" checks. This is because the default can change arbitrarily, and may change to be the pinned version they specify. e.g. if a module tries to do this:
pip.parse(python_version="3.10", ...)
pip.parse(<python_version unset, so use default>)
Today, that would use 3.10 and 3.11. But a different root module might override to use 3.10 -- now the child will get an error because 3.10 occurs twice. But if it removes it, things fail because the default wasn't specified.
The check is around here: https://github.com/bazelbuild/rules_python/blob/main/python/extensions/pip.bzl#L294