Skip to content

Replace pkg_resources with importlib#501

Open
cas-- wants to merge 3 commits intodeluge-torrent:developfrom
cas--:feat/drop-pkg-resources
Open

Replace pkg_resources with importlib#501
cas-- wants to merge 3 commits intodeluge-torrent:developfrom
cas--:feat/drop-pkg-resources

Conversation

@cas--
Copy link
Copy Markdown
Member

@cas-- cas-- commented Mar 7, 2026

No description provided.

cas-- added 3 commits March 7, 2026 23:20
- also remove unneeded fallback pkg_resources in common
…rces

Replicate the functionality of pkg_resources with stdlib

- ensure plugin manager picks latest version
- prefer source dir over eggs
- extract zip eggs to real paths to ensure usable resources files
- activate plugins using sys.meta_path instead sys.path to avoid global
  namespace probems and compatibility with pyinstaller.
Return a str instead of Path since most resource usage requires a str
filepath e.g. GTK builder calls.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant