Skip to content
This repository has been archived by the owner on Apr 3, 2023. It is now read-only.

Script broken, ZS change? #11

Closed
DarrenPIngram opened this issue Dec 23, 2021 · 6 comments
Closed

Script broken, ZS change? #11

DarrenPIngram opened this issue Dec 23, 2021 · 6 comments

Comments

@DarrenPIngram
Copy link

Previously things seemed to work. Am on the latest version. Has ZS changed something, or has something broken locally I've not been aware of?

% zippyshare-dl --verbose url.txt
[INFO] Grabbing required informations in https://www61.zippyshare.com/v/op8XYTSL/file.html
[DEBUG] Establishing connection to Zippyshare.
[DEBUG] Successfully established connection to Zippyshare.
[DEBUG] Checking if file is not expired
[DEBUG] Checking if file is exist
[DEBUG] Getting Name file, size, date upload.
[DEBUG] Getting download url.
[DEBUG] pattern1 failed to get download url, ParserError: omg attribute in download button javascript cannot be found
[DEBUG] pattern2 failed to get download url, NameError: The use of 'n' is not allowed. Expression used: n + b + z - 3
[ERROR] all patterns parser failed to get required informations
NoneType: None
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.9/bin/zippyshare-dl", line 33, in <module>
    sys.exit(load_entry_point('zippyshare-downloader==0.2.0', 'console_scripts', 'zippyshare-dl')())
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/zippyshare_downloader/cli/process.py", line 110, in main
    process(**kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/zippyshare_downloader/cli/process.py", line 39, in process
    files = download(*urls, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/zippyshare_downloader/fetcher.py", line 111, in download
    info = get_info(url)
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/zippyshare_downloader/fetcher.py", line 46, in get_info
    return finalization_info(parse_info(url, r.text))
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/zippyshare_downloader/parser.py", line 52, in parse_info
    raise ParserError('all patterns parser is failed to get required informations')
zippyshare_downloader.errors.ParserError: all patterns parser is failed to get required information


The file url.txt has two URLs.

% cat url.txt
https://www61.zippyshare.com/v/op8XYTSL/file.html
https://www70.zippyshare.com/v/Vz9vh7DJ/file.html

@mansuf
Copy link
Owner

mansuf commented Dec 23, 2021

That's weird. In zippyshare-downloader v0.2.0 this should be fixed, i added additional patterns (pattern3) for grabbing zippyshare download urls in v0.2.0

@mansuf
Copy link
Owner

mansuf commented Dec 23, 2021

$ zippyshare-dl "https://www61.zippyshare.com/v/op8XYTSL/file.html" --no-download --verbose && zippyshare-dl "https://www70.zippyshare.com/v/Vz9vh7DJ/file.html" --no-download --verbose
[INFO] Grabbing required informations in https://www61.zippyshare.com/v/op8XYTSL/file.html
[DEBUG] Establishing connection to Zippyshare.
[DEBUG] Successfully established connection to Zippyshare.
[DEBUG] Checking if file is not expired
[DEBUG] Checking if file is exist
[DEBUG] Getting Name file, size, date upload.
[DEBUG] Getting download url.
[DEBUG] pattern1 failed to get download url, ParserError: omg attribute in download button javascript cannot be found
[DEBUG] pattern2 failed to get download url, NameError: The use of 'n' is not allowed. Expression used: n + b + z - 3
[DEBUG] pattern3 success to get download url
{"name_file": "Weakest Link Christmas Special.mp4.part1.rar", "size": "500 MB", "date_upload": "23-12-2021 04:15", "download_url": "https://www61.zippyshare.com/d/op8XYTSL/366872/Weakest%20Link%20Christmas%20Special.mp4.part1.rar"}
[INFO] Grabbing required informations in https://www70.zippyshare.com/v/Vz9vh7DJ/file.html
[DEBUG] Establishing connection to Zippyshare.
[DEBUG] Successfully established connection to Zippyshare.
[DEBUG] Checking if file is not expired
[DEBUG] Checking if file is exist
[DEBUG] Getting Name file, size, date upload.
[DEBUG] Getting download url.
[DEBUG] pattern1 failed to get download url, ParserError: omg attribute in download button javascript cannot be found
[DEBUG] pattern2 failed to get download url, NameError: The use of 'n' is not allowed. Expression used: n + b + z - 3
[DEBUG] pattern3 success to get download url
{"name_file": "Weakest Link Christmas Special.mp4.part2.rar", "size": "88.51 MB", "date_upload": "23-12-2021 04:15", "download_url": "https://www70.zippyshare.com/d/Vz9vh7DJ/12148/Weakest%20Link%20Christmas%20Special.mp4.part2.rar"}

Your urls works fine, i used v0.2.0 tho. Maybe check your installation ?

@DarrenPIngram
Copy link
Author

Hmm, I updated with the pip package manager. Sorry if there's a false alarm.

I am not sure, what's the best way to delete the entire installation and reinstall from git?

@mansuf
Copy link
Owner

mansuf commented Dec 23, 2021

I am not sure, what's the best way to delete the entire installation and reinstall from git?

pip3 uninstall zippyshare-downloader && pip3 install -U zippyshare-downloader

This will reinstall zippyshare-downloader with pip

However, if you still want to uninstall & install from git

pip3 uninstall zippyshare-downloader && pip3 install git+https://github.com/mansuf/zippyshare-downloader.git@v0.2.0

@DarrenPIngram
Copy link
Author

DarrenPIngram commented Dec 23, 2021

Thank you. I used the git version (seems better in case the pip manager has its own source -- that I don't know).

This worked, but I don't know what might have corrupted the previous installation that had worked very well. Anyway, thank you for your assistance and for developing this very useful script/application.

Could I suggest adding the "reinstall" instructions to the main page for the benefit of people like me ?

@mansuf
Copy link
Owner

mansuf commented Dec 23, 2021

Sure 👍, i will add it. This issue is closed.

@mansuf mansuf closed this as completed Dec 23, 2021
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants