Phoenix124 / scribd-downloader

319 stars 105 forks source link

Credentials issue #41

Open olafx opened 2 years ago

olafx commented 2 years ago

Credentials aren't working. Not sure why, error gives no hints. The credentials file exists (it gives a different error when I remove it) and doesn't seem to be a permissions issue, doesn't work with sudo either.

(main) swift@taylor ~ % scribdl -c scribd_credentials.txt https://www.scribd.com/read/332994411/The-Three-Body-Problem
/Users/swift/venv/main/lib/python3.9/site-packages/cryptography/hazmat/backends/openssl/x509.py:15: CryptographyDeprecationWarning: This version of cryptography contains a temporary pyOpenSSL fallback path. Upgrade pyOpenSSL now.
  warnings.warn(
Traceback (most recent call last):
  File "/Users/swift/venv/main/bin/scribdl", line 33, in <module>
    sys.exit(load_entry_point('scribd-downloader==1.3.1', 'console_scripts', 'scribdl')())
  File "/Users/swift/venv/main/lib/python3.9/site-packages/scribd_downloader-1.3.1-py3.9.egg/scribdl/command_line.py", line 51, in _command_line
  File "/Users/swift/venv/main/lib/python3.9/site-packages/scribd_downloader-1.3.1-py3.9.egg/scribdl/authorize.py", line 55, in set_credentials
scribdl.exceptions.ScribdFetchError: Login error: An error occurred please try again.
SigmaDuck894 commented 2 years ago

I have also run into this issue. It seems like Scribd modify their site for this to not work. Hope someone can fix this.

Traceback (most recent call last): File "C:\Users\Dell\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "C:\Users\Dell\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code exec(code, run_globals) File "C:\Users\Dell\AppData\Local\Programs\Python\Python310\Scripts\scribdl.exe__main__.py", line 7, in File "C:\Users\Dell\AppData\Local\Programs\Python\Python310\lib\scribdl\command_line.py", line 51, in _command_line authorize.set_credentials(credentials_file) File "C:\Users\Dell\AppData\Local\Programs\Python\Python310\lib\scribdl\authorize.py", line 55, in set_credentials raise exceptions.ScribdFetchError("Login error: " + errors[0]["msg"]) scribdl.exceptions.ScribdFetchError: Login error: An error occurred please try again.

DanielBananinha commented 2 years ago

Any resolution?

flagmaggot commented 2 years ago

Well you can enter your own _session_expire and _scribd_session values but even then it only downloads the first page.

fvbatistoni commented 2 years ago

I have the same problem. I have edited const.py with cookie information, and created scribd_credentials.txt with two single lines (username and password)....


osboxes@osboxes:~/Downloads/scribd-downloader$ scribdl -c scribd_credentials.txt https://www.scribd.com/read/425270864/What-Does-It-Mean-to-Be-Welcoming-Navigating-LGBT-Questions-in-Your-Church Traceback (most recent call last): File "/usr/local/bin/scribdl", line 33, in sys.exit(load_entry_point('scribd-downloader==1.3.1', 'console_scripts', 'scribdl')()) File "/usr/local/lib/python3.10/dist-packages/scribd_downloader-1.3.1-py3.10.egg/scribdl/command_line.py", line 51, in _command_line File "/usr/local/lib/python3.10/dist-packages/scribd_downloader-1.3.1-py3.10.egg/scribdl/authorize.py", line 55, in set_credentials scribdl.exceptions.ScribdFetchError: Login error: An error occurred please try again.

matthew-clark3 commented 1 year ago

Same issue. Use of the .egg file makes creating a work around frustrating.

dylb0t commented 1 year ago

Same issue. Use of the .egg file makes creating a work around frustrating.

If you use VSCode, create a launch.json and a settings.json in the .vscode folder. This will allow you to debug. The egg is used only if you run the setup.py to install.

settings.json { "version": "0.2.0", "configurations": [ { "python.analysis.extraPaths": [ "${workspaceFolder}/scribdl/,${workspaceFolder}/scribdl_downloader,${workspaceFolder}/build" ] } ] } launch.json (fill credentials.txt with your login credentials, in the root. Also put an audiobook you have access to. { // Use IntelliSense to learn about possible attributes. // Hover to view descriptions of existing attributes. // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 "version": "0.2.0", "configurations": [ { "name": "Python: scribdl commandline Module", "type": "python", "request": "launch", "module": "scribdl.command_line", "justMyCode": true, "args": [ "https://www.scribd.com/audiobook/237606860/100-Ways-to-Motivate-Yourself-Change-Your-Life-Forever", "-c", "credentials.txt" ], "env": { "PYTHONPATH": "${workspaceFolder}/scribdl" }, "autoReload": { "enable": true } }

dylb0t commented 1 year ago

This is where we get to in the debug: {"form_name":null,"errors":[{"input_name":"login_or_email","msg":"An error occurred please try again."}]} it is in authorize.py, and right when you get the response on around line 43. I checked the values in the SCRIBD_LOGIN_DATA and they are correct. This is as far as I have made it so far, so probably need somebody with soup knowlege to help here.

theoriginalbxhx commented 1 year ago

Has there been any headway made with this? I'm having the same issue.

$ scribdl -c scribd_credentials.txt https://www.scribd.com/read/235007189/A-Basic-Guide-to-Interpreting-the-Bible-Playing-by-the-Rules Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.11/bin/scribdl", line 8, in <module> sys.exit(_command_line()) ^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/scribdl/command_line.py", line 51, in _command_line authorize.set_credentials(credentials_file) File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/scribdl/authorize.py", line 55, in set_credentials raise exceptions.ScribdFetchError("Login error: " + errors[0]["msg"]) scribdl.exceptions.ScribdFetchError: Login error: An error occurred please try again.