https://fedoraproject.org/wiki/Changes/PythonDistPEP503ProvidesOnly == Summary == The legacy `python3dist(NAME)` and `python3.11dist(NAME)` RPM provides with dots (`.`) in `NAME` will no longer be automatically provided. `NAME` will only be normalized according to [https://www.python.org/dev/peps/pep-0503/#normalized-names PEP 503]. E.g. on Fedora 36 a package provides both `python3dist(ruamel-yaml)` and `python3dist(ruamel.yaml)`, on Fedora 37+ it will only provide `python3dist(ruamel-yaml)` (and similarly, `python3.11dist(ruamel-yaml)`. == Owner == * Name: [[User:Churchyard|Miro Hrončok]] * Email: mhroncok@xxxxxxxxxx == Detailed Description == This change is only about about automatic RPM provides in the following forms: * `python3dist(NAME)` * `python3.Xdist(NAME)` It does not affect any other provides or package names. Historically, Python package names were normalized by the RPM dependency generators in a way that diverged from upstream behavior. In upstream (e.g. when using `pip`) a package name with a dot is equal to a package name with a dash (e.g. `pip install ruamel.yaml` and `pip install ruamel-yaml` are equivalent). In Fedora, the ''Provides'' and ''Requires'' included the dot, but upstream rules defined in [https://www.python.org/dev/peps/pep-0503/#normalized-names PEP 503] demand the dot to be replaced by a dash. This caused trouble when other packages required the packages via a name with a dash. Hence, we have slowly been migrating to PEP 503 name normalization. * Since Fedora 32, Python dependency generators have generated both variants of the ''Provides'' as a preparation for the transition to PEP 503-only. * Since Fedora 33, Python dependency generators have generated ''Requires'' in the PEP 503 form (no dots). * Only packages with manual ''BuildRequires'', ''Requires'', ''Recommends'' etc. with requirements such as `python3dist(foo.bar)` would be affected by this change. We have fixed all of them in Fedora 36. Hence, together with [[Changes/Python3.11|the update to Python3.11]], we will disable the legacy form of the provides. Python packages with dots in their name will only provide the names with dashes. === RHEL/EPEL compatibility === This change is fully compatible with RHEL/EPEL 9, which behaves like Fedora 34 and hence has ''Provides'' in both forms but ''Requires'' in the PEP 503 form (no dots). This change is not compatible with RHEL/EPEL 8. If you need to have manual requirements in the specfile that should work on Fedora 37+ and RHEL/EPEL 8 in this form and the name includes a dot, we recommend using [https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#py3_dist `%py3_dsit`]. This change is not relevant to RHEL 7. This change is not compatible with EPEL 7. If you need to have manual requirements in the specfile that should work on Fedora 37+ and RHEL/EPEL 7 in this form and the name includes a dot, we recommend using [https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#py3_dist `%py3_dsit`]. == Benefit to Fedora == * Less automatic provides in the repos - there are 93+93=186 provides like `python3dist(x.y)` and `python3.Xdist(x.y)` in rawhide today. * There will be only way way to express a Python package name in this context, not two. * One more thing the Python maintainers will cross off their TODO list. == Scope == * Proposal owners: # check there are really no more manual requirements with dots # disable the automatically generated provides with dots when we update to Python 3.11 # double-check there are really no more manual requirements with dots * Other developers: ** stop adding new manual Python dist requirements with dots * Release engineering: not needed for this Change * Policies and guidelines: they already only cover PEP 503 * Trademark approval: not needed for this Change * Alignment with Objectives: not really == Upgrade/compatibility impact == This is done together with the Python 3.11 update to not have to deal with little problems, such as packages that can't be rebuilt after the manual requirements were changed. == How To Test == The following 2 commands should yield nothing: $ repoquery --repo=rawhide --provides | grep -E '^python3(\.[[:digit:]]+)?dist\(\S+\.\S+\)' $ repoquery --repo=rawhide --requires | grep -E '^python3(\.[[:digit:]]+)?dist\(\S+\.\S+\)' With the exception of packages that failed to rebuild with Python 3.11 (and those will need to be dealt with anyway one way or another). The following example commands should only give the variant with dashes: $ repoquery --repo=rawhide --provides python3-ruamel-yaml | grep -E '^python3(\.[[:digit:]]+)?dist\(' $ repoquery --repo=rawhide --provides python3-jaraco-path | grep -E '^python3(\.[[:digit:]]+)?dist\(' There should be no new broken dependencies because of this. Note that wiki is eating my double `[]` in the regexes above around `:digit:`. See the page source for the actual commands :( == User Experience == The actual users should notice no difference. == Dependencies == We need [[Changes/Python3.11]] to happen together with this. == Contingency Plan == * Contingency mechanism: the change owners will revert the change and the mass rebuild will handle the packages that need the legacy form of the provides * Contingency deadline: mass rebuild * Blocks release? No == Documentation == N/A (not a System Wide Change) -- Ben Cotton He / Him / His Fedora Program Manager Red Hat TZ=America/Indiana/Indianapolis _______________________________________________ devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure