Description of problem: stratis-cli has broken dependencies in RHEL-9 Version-Release number of selected component (if applicable): RHEL-9.0.0-20210626.0 stratis-cli-2.4.2-2.el9 Steps to Reproduce: Try to install the package Actual results: package: stratis-cli-2.4.2-2.el9.noarch from AppStream unresolved deps: python3.9dist(semantic-version) python3.9dist(wcwidth) Expected result: Package installable and no broken dependencies
You'll have to explain how you arrived at this problem. Here is the spec file for stratis-cli for RHEL9: https://src.osci.redhat.com/rpms/stratis-cli/blob/rhel-9.0.0-beta/f/stratis-cli.spec It requires neither semantic_version nor wcwidth. According to our understanding these explicit requires in the RHEL9 spec file should ensure that only these packages are required during the installation. The same approach worked excellently well in RHEL8. It seems like, even with the spec file that we use, dependencies are now being generated from the upstream Python package's setup.py. That's wrong, and that is precisely what we need to fix. Do you have any further information on why that is happening in RHEL9 and not in RHEL8? Thanks! - mulhern
%py3_install is what builds the egg-info package; in that package is information about the requirements. It is possible that RHEL9 packaging is somehow ignoring explicit requirements in spec file and extracting them from the egg-info directory instead. If so, we need to figure out how to prevent that or override it.
I installed RHEL-9.0.0-20210626.0 on a test system, and executed "dnf install stratisd stratis-cli, and this is the output from that command: Error: Problem: conflicting requests - nothing provides python3.9dist(semantic-version) needed by stratis-cli-2.4.2-2.el9.noarch - nothing provides python3.9dist(wcwidth) needed by stratis-cli-2.4.2-2.el9.noarch (try to add '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages) ...and yet, neither of those packages are specified as a "Requires:" in the stratis-cli.spec file.
@pzatko We have reproduced the problem and understand why it is happening although we don't yet know what the solution should be. Did you encounter this error as part of some automated rebuild activity or did you run across it by accident, or...? Thanks!
It seems that mock is now scanning setup.py for the "install_requires" section. If I add a patch file with the following, it successfully builds in mock, without the dependencies: --- setup.py.orig 2021-06-28 12:47:21.861294270 -0400 +++ setup.py 2021-06-28 12:47:36.575294270 -0400 @@ -51,8 +51,6 @@ setuptools.setup( "justbytes>=0.14", "psutil", "python-dateutil", - "semantic_version", - "wcwidth", ], package_dir={"": "src"}, packages=setuptools.find_packages("src"),
I've submitted a pull request to c9s using the patch mentioned above, at the following URL: https://gitlab.com/redhat/centos-stream/rpms/stratis-cli/-/merge_requests/4
@mulhern we run `dnf repoclosure` test on every compose, to find packages with broken dependencies, as part of RTT compose tier1 testing.
A fix has been merged into c9s as stratis-cli-2.4.2-3.
Verified with stratis-cli-2.4.2-3.el9.