On 29. 04. 20 18:51, Neal Gompa wrote:
What do you think? Do you foresee any problems?
I'm good with this plan, except for one thing I thought of we need to address: How do we do comparisons for python versions?
In spec %ifs? I've been doing it with %python3_version_nodots. That'll work until there is 3.10 and later 4.0. At that point, it will break because 310 > 40. If there is Python 4, this will be the smallest of our problems.
Will we still have a %python_version_nodots macro so that we can do integer comparisons?
Yes. The macro has the Python version without dots. It has nothing to do with package names and never had.
I know that people have been abusing the %python3_pkgversion macro for doing this (which you shouldn't be doing!)
Oh my gods. That cannot even work, %python3_pkgversion is always 3 in Fedora. Are you talking EPEL? EPEL Python packaging is a spaghetti western, if people do this, they are on their own.
I've recently seen this in Fedora spec:
pytest-%{python3_pkgversion}
Well, it works. In the same way this works:
%if %{fedora} > %{python3_pkgversion}0
Don't do this. Ever.
so we need an official guideline for how to do those comparisons.
Good point. I'll take a note.