Replace pkg_resources with packaging for Python 3.13/3.14 support#127
Open
mike1872ai wants to merge 1 commit intoperiareon:mainfrom
Open
Replace pkg_resources with packaging for Python 3.13/3.14 support#127mike1872ai wants to merge 1 commit intoperiareon:mainfrom
mike1872ai wants to merge 1 commit intoperiareon:mainfrom
Conversation
ebabf78 to
a4eb0f5
Compare
518fe2a to
e1ae108
Compare
Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
e1ae108 to
0249547
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Migrates all
pkg_resourcesusage to thepackaginglibrary, enabling Python 3.13 and 3.14 support. Bumps version to 1.1.0.Key changes
pkg_resourceswithpackagingacross 17 source files and 13 test files (~90 call sites)pkg_resources.Requirement.parse()→packaging.requirements.Requirement()pkg_resources.parse_version()→packaging.version.Version().project_name→.name,.specs→.specifier,version in req→req.specifier.contains()EggInfoDistInfoclass incontainers.pyreplacesPkgResourcesDistInfo— manually parsesPKG-INFOandrequires.txtfrom.egg-infodirectoriessource.pyandextractor.py— normalized paths before comparison to handle mixed separators on Windows 3.13+distutils.util.get_platform()→sysconfig.get_platform(),distutils.corewrapped intry/except,imp→importlibfallbackpylint3.1→3.3.5,mypy1.4→1.15,astroid3.1→3.3.8 for 3.13/3.14 supporttyped-astandtyping_extensionsas direct depsScope
pkg_resourcesimports remain in source codeTest plan
pytest: 363 passed, 1 skipped (local, Python 3.10)mypy: no issues in 26 source filespylint: 10.00/10black/isort: all files properly formattedCloses #126