ert-downloader icon indicating copy to clipboard operation
ert-downloader copied to clipboard

more dependencies and cannot import sanit from pathvalidate

Open christosk opened this issue 3 years ago • 0 comments

I can't get the script run: missing dependencies

I cloned the ert-downloader from github and tried to download a video from ertflix. First the script was not able to find the bs4 module. So I install python3-bs4 on my fresh Debian 11 installation (e.g. by su -l apt install python3-bs4).

The next missing module was pathvalidate. So I tried to install it via apt. The commands that seems necessary are: su -l add-apt-repository ppa:thombashi/ppa apt update apt install python3-pathvalidate

Trying add-apt-repository ppa:thombashi/ppa leads to the following error message:

kRyzen7:~# add-apt-repository ppa:thombashi/ppa deb packages of my repositories (https://github.com/thombashi). PPA packaging sources can be found at https://github.com/thombashi/PPA More info: https://launchpad.net/~thombashi/+archive/ubuntu/ppa Press [ENTER] to continue or ctrl-c to cancel adding it

gpg: Die "Keybox" /tmp/tmprksegdde/pubring.gpg' wurde erstellt gpg: /tmp/tmprksegdde/trustdb.gpg: trust-db erzeugt gpg: Schlüssel CF9859CE95D9F1E2: Öffentlicher Schlüssel "Launchpad PPA for Tsuyoshi Hombashi" importiert gpg: Anzahl insgesamt bearbeiteter Schlüssel: 1 gpg: importiert: 1 Warning: apt-key is deprecated. Manage keyring files in trusted.gpg.d instead (see apt-key(8)). gpg: Keine gültigen OpenPGP-Daten gefunden.

My interpretation is that an old method (apt-key) is used in thombashi's script. Maybe this method is no longer support by the apt version used in Debian 11. I will contact thombashi-san to find out more and will report how this can be solved.

As I was not able to install pathvalidate via apt I installed pip and than pathvalidate via pip:

(as superuser) apt install python3-pip and as normal user : pip install pathvalidate. This seems to have been successfull:

Collecting pathvalidate Downloading pathvalidate-2.5.0-py3-none-any.whl (19 kB) Installing collected packages: pathvalidate Successfully installed pathvalidate-2.5.0

But still the ert-download script does not find pathvalidate:

python3 ert-downloader.py https://www.ertflix.gr/vod/vod.172529-the-thing-about-greece Traceback (most recent call last): File "/home/user/Downloads/ert-downloader/ert-downloader.py", line 2, in from downloaders import m3u8_downloader, alpha_downloader File "/home/user/Downloads/ert-downloader/downloaders/m3u8_downloader.py", line 8, in from pathvalidate import sanit ImportError: cannot import name 'sanit' from 'pathvalidate' (/home/user/.local/lib/python3.9/site-packages/pathvalidate/init.py)

Now I really don't know how to solve this. Anyone hints?

christosk avatar Jan 04 '22 21:01 christosk