Remove usage of pkg_resources#2036
Conversation
Currently, a warning is emitted on each run:
UserWarning: pkg_resources is deprecated as an API. See
https://setuptools.pypa.io/en/latest/pkg_resources.html. The
pkg_resources package is slated for removal as early as 2025-11-30.
Refrain from using this package or pin to Setuptools<81.
This patch removes all usage of that package.
Fixes fortra#1645.
|
hey @AdrianVollmer, thanks for this PR!! been checking it and have only one doubt, related to the |
|
Good catch, we need to add Since impacket seems to support python 3.8 and higher, I suppose we can remove the try-exception block in
So if impacket wants to support py3.8, we need to catch that exception. I'll push another commit. Let me know what you think. (Minor remark: the |
|
Thank you! mm yeah, that's true. Will check with the other maintainers and update here later today (being py3.8 an already EoL version perhaps we wanna remove it for next impacket version - as matter of fact, unit tests are not being executed for py3.8) Will let you know later, thanks! |
|
hey, yes... we'll remove support for python 3.8 in the next release. We did it in the context of #1965 but didn't reflect this new req in the README (will update that now) but, yes, I'd remove that exception catching there to simplify the code Thanks! |
|
Done! I can squash the commits if you prefer that |
|
Thank you @AdrianVollmer, merging now! |
It's needed to run `setup.py` itself, but that's not what `install_requires` is for, and the rest of the package no longer uses it (since fortra#2036). I deliberately left the entry in `requirements.txt` in place, since that's used by CI.
It's needed to run `setup.py` itself, but that's not what `install_requires` is for, and the rest of the package no longer uses it (since #2036). I deliberately left the entry in `requirements.txt` in place, since that's used by CI.
Currently, a warning is emitted on each run:
This patch removes all usage of that package.
Fixes #1645.