[Plugins] Fix allow enabling any plugin Python version

Properly fix allow enabling any plugin Python version, first attempted
in previous commit 3433a91

Closes: deluge-torrent/deluge#316
This commit is contained in:
Martin Hertz 2021-11-05 20:58:26 +01:00 committed by Calum Lind
parent d56636426e
commit 7a110bd60f
1 changed files with 3 additions and 1 deletions

View File

@ -105,7 +105,9 @@ class PluginManagerBase(object):
for dirname in plugin_dirs: for dirname in plugin_dirs:
pkg_resources.working_set.add_entry(dirname) pkg_resources.working_set.add_entry(dirname)
self.pkg_env = pkg_resources.Environment(plugin_dirs, None) self.pkg_env = pkg_resources.Environment(
plugin_dirs, platform=None, python=None
)
self.available_plugins = [] self.available_plugins = []
for name in self.pkg_env: for name in self.pkg_env: