Skip to content

Commit

Permalink
Seperate import of lazy_extractors from that of normal extractors
Browse files Browse the repository at this point in the history
This prevents "ModuleNotFoundError: No module named 'youtube_dl.extractor.lazy_extractors'" from appearing in the traceback

Related: animelover1984/youtube-dl#17 (comment)
  • Loading branch information
pukkandan committed Jan 28, 2021
1 parent 6b591b2 commit 0748b33
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion youtube_dlc/extractor/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@
from .lazy_extractors import _ALL_CLASSES
_LAZY_LOADER = True
_PLUGIN_CLASSES = []

except ImportError:
_LAZY_LOADER = False

if not _LAZY_LOADER:
from .extractors import *

_PLUGIN_CLASSES = load_plugins('extractor', 'IE', globals())
Expand Down

0 comments on commit 0748b33

Please sign in to comment.