Sujet : Re: Correct module for site customization of path
De : dieter.maurer (at) *nospam* online.de
Groupes : comp.lang.pythonDate : 01. Nov 2024, 18:32:04
Autres entêtes
Message-ID : <mailman.66.1730479505.4695.python-list@python.org>
References : 1 2
User-Agent : VM 8.0.12-devo-585 under 21.4 (patch 24) "Standard C" XEmacs Lucid (x86_64-linux-gnu)
...
After the recent upgrades I had to install youtube_dl with pipx for the
new python version.
When I ran the script which imported youtube_dl, I got an import error
as it appears the path to the module
was not in sys.path....
I see at several options:
* install `youtoube_dl` where Python looks for it
(you can print `sys.path` to find out all the places
normally checked for importable modules)
* put a (symbolic) link to `youtoube_dl` at a place
where Python looks for modules
* use Pythons' `.pth' feature to tell Python additional
places where to look for modules.
You can place `.pth` files where Python looks for modules
to be imported