mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-05 16:08:40 +00:00
Drop pkutil and simply use pkg_resources.
This commit is contained in:
parent
16f617d240
commit
f17634ea63
4 changed files with 8 additions and 25 deletions
|
@ -1,8 +1,4 @@
|
||||||
"""Deluge"""
|
"""Deluge"""
|
||||||
# this is a namespace package
|
# this is a namespace package
|
||||||
try:
|
|
||||||
import pkg_resources
|
import pkg_resources
|
||||||
pkg_resources.declare_namespace(__name__)
|
pkg_resources.declare_namespace(__name__)
|
||||||
except ImportError:
|
|
||||||
import pkgutil
|
|
||||||
__path__ = pkgutil.extend_path(__path__, __name__)
|
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
# this is a namespace package
|
# this is a namespace package
|
||||||
try:
|
|
||||||
import pkg_resources
|
import pkg_resources
|
||||||
pkg_resources.declare_namespace(__name__)
|
pkg_resources.declare_namespace(__name__)
|
||||||
except ImportError:
|
|
||||||
import pkgutil
|
|
||||||
__path__ = pkgutil.extend_path(__path__, __name__)
|
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
# this is a namespace package
|
# this is a namespace package
|
||||||
try:
|
|
||||||
import pkg_resources
|
import pkg_resources
|
||||||
pkg_resources.declare_namespace(__name__)
|
pkg_resources.declare_namespace(__name__)
|
||||||
except ImportError:
|
|
||||||
import pkgutil
|
|
||||||
__path__ = pkgutil.extend_path(__path__, __name__)
|
|
||||||
|
|
|
@ -1,8 +1,3 @@
|
||||||
# this is a namespace package
|
# this is a namespace package
|
||||||
try:
|
|
||||||
import pkg_resources
|
import pkg_resources
|
||||||
pkg_resources.declare_namespace(__name__)
|
pkg_resources.declare_namespace(__name__)
|
||||||
except ImportError:
|
|
||||||
import pkgutil
|
|
||||||
__path__ = pkgutil.extend_path(__path__, __name__)
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue