rpmlint
rpmlint copied to clipboard
Warn against python setup.py test construct
https://github.com/pypa/setuptools/issues/1684
python setup.py test
subcommand has been deprecated, users should be warned against using it.
I see. So should we warn about any %python_exec setup.py test
call in a spec file?
Are you willing to create a pull request for it?
Looking at openSUSE:Factory
package, there are quite some:
grep 'setup.py test' *.spec | wc -l
162
Yes, and when I have time eventually (and I would love somebody beat me to it).
Yes, I am aware, but I hope that exactly rpmlint warning could be helpful in identifying and eliminating the crap.
What benefit do we have to do this without providing a useful alternative to users? One thing I don't want to have is more warnings/errors that people can't do anything about, and this is one that would generally fall in that class.
Users? rpmlint is not for users but for packagers, who can very well do something about it.
If they don't know how to fix the Python code for running tests, they may not be able to.
This is just absurd! 90% of all cases is just replacing the construct with %pytest
or %pyunittest discover -v
. Python maintainers who cannot maintain Python packages are hopefully an exception not the rule which we need to accommodate.