fedora-infra / koschei

Continuous integration for Fedora packages
GNU General Public License v2.0
37 stars 15 forks source link

Conditional build dependencies seem to be resolved on wrong Fedora version #295

Open hroncok opened 5 years ago

hroncok commented 5 years ago

See pytest on f32. It says:

No package found for: (python3-importlib-metadata if python3 < 3.8)

While python3 on Fedora 32 is 3.8.

I can probably workaround this by adding an %if around the BR and rebuild the package, but I wonder how does the dependency resolution actually work. Is it resolved on some other Fedora version?

cc @encukou

mizdebsk commented 5 years ago

I can reproduce this issue locally. Reproducer: https://gist.github.com/mizdebsk/2ff126556cff0fa42d8111e2094c2033

Koschei resolves dependencies using libdnf. It seems that libdnf is checking python3 version on the system it is running, not in configured sack. This will require further investigation.