-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
[BR]: fail2ban relies on deprecated, soon-to-be-removed setuptools install functionality #3999
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
You seem to misunderstand the deprecation: it is not the Particularly if I try this on my box with newest setuptools, I don't see any warning and it simulates the installation without any issue:
Also note that the packaging is rather a matter of distribution maintainers and their common mechanisms or tools used by distribution. We have surely to adjust the README and the wiki for "new" syntax of manual install, but the assumption "fail2ban relies on deprecated, soon-to-be-removed setuptools install functionality" is not correct. |
Hello. Please show me the contents of your systemd service file that is installed by |
I haven't confused them. Please see the links I gave and my description above. The wheel format can't actually handle auxiliary data files like configuration in
I am such a distribution maintainer, and I'm reaching out to explain the problem. Right now, fail2ban's build system requires manual hacks (which every distribution will have to do) to handle the files fail2ban needs outside of |
We don't install it (and never did it) by manual install - as the README and wiki say, the build folder would contain
Doesn't gentoo have build tools like pybuild/dh? Or is that mentioned Meson such a tool? And are this "manual hacks" not just few rules for packaging tool to package paths like this?
Anyway, why don't you provide your build scripts (Meson or whatever), so other maintainers would not require manual hacks? |
As was mentioned by the setuptools maintainer on the linked ticket:
My reply there was very specific about the issues which exist in practice, for fail2ban itself:
|
So, using pip install produces wheels, which tells fail2ban to produce the wrong file contents for the systemd service and openrc init file. They can't be used. Gentoo manually copies them over, but we also use |
Note this problem cannot be solved by pip because pip now requires that you do NOT install software directly, but first build a generic "wheel" package with unfixed relative paths. As discussed at pypa/packaging-problems#576 (comment) -- the python packaging community has officially deprecated and removed support for installing system integration. If your software doesn't install into a python virtualenv as standalone, it isn't a good fit for pip. If you have /etc files, you aren't supported. If you need to install GUI
I may look into this soon, if nobody else beats me to it. :) |
… (not yet ready) to fulfill the build and installation processes if deprecated `install` method gets removed and pip (setuptools-via-PEP517) wouldn't install anything excepting library; closes gh-3999
How about this one?.. For instance, to make build folder (very similar to deprecated python3 setup.py build-ex --build-base=build --without-tests (it is also covered in GHA now - see actions/runs/14814502138 for the output) Use
( This doesn't rely on deprecated mechanisms anymore. If it is OK, I'd fulfill the |
small amend: commands |
Option
This would firstly build to folder "./build" (using Anyway it looks completed to me now, reviews and tests are welcome. |
Environment:
The issue:
fail2ban currently relies on setuptools
setup.py install
, but this has been marked deprecated for quite some time. In setuptools-80.1.0, they've finally set a removal date for 2025-10-31.Steps to reproduce
After 2025-10-31, that deprecation warning will become fatal, and
setup.py install
won't work at all.In summary, the Python ecosystem decided that the
setup.py install
way of doing things was too haphazard. There are two models now:A lot of software written in Python was relying on
setup.py install
because it seemed like the right thing to do, but there's no reason that software just written in Python that isn't intended to be imported or must live insite-packages
has to be installed by the Python packaging setup (especially if it's not intended to be installed viapip
or onpypi
at all).I personally recommend Meson for this case.
Expected behavior
No deprecation warnings.
Observed behavior
Deprecation warnings indicating imminent breakage.
Any additional information
See also #3361, pypa/setuptools#2088 (comment), and pypa/packaging-problems#576 (comment)
The text was updated successfully, but these errors were encountered: