Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[reddit] oauth error from TERMUX #3947

Closed
Kavolc opened this issue Apr 23, 2023 · 1 comment
Closed

[reddit] oauth error from TERMUX #3947

Kavolc opened this issue Apr 23, 2023 · 1 comment

Comments

@Kavolc
Copy link

Kavolc commented Apr 23, 2023

How do I run "gallery-dl oauth:reddit" from termux? I got a message "no runnable browser found"

$ gallery-dl oauth:reddit  --verbose
[gallery-dl][debug] Version 1.25.0
[gallery-dl][debug] Python 3.11.0 - Linux-4.19.152-perf-21186317-abA526U1UES2AUD5-aarch64-with-libc
[gallery-dl][debug] requests 2.28.1 - urllib3 1.26.12
[gallery-dl][debug] Configuration Files ['${HOME}/.config/gallery-dl/config.json']
[gallery-dl][debug] Starting DownloadJob for 'oauth:reddit'
[oauth][debug] Using OAuthReddit for 'oauth:reddit'
[oauth][info] Using default reddit client ID (6N9uN0krSDE-ig)
[oauth][error] An unexpected error occurred: Error - could not locate runnable browser. Please run gallery-dl again with the --verbose flag, copy its output and report this issue on https://github.com/mikf/gallery-dl/issues .
[oauth][debug]
Traceback (most recent call last):
  File "/data/data/com.termux/files/usr/lib/python3.11/site-packages/gallery_dl/job.py", line 96, in run
    for msg in extractor:
  File "/data/data/com.termux/files/usr/lib/python3.11/site-packages/gallery_dl/extractor/oauth.py", line 323, in items
    self._oauth2_authorization_code_grant(
  File "/data/data/com.termux/files/usr/lib/python3.11/site-packages/gallery_dl/extractor/oauth.py", line 160, in _oauth2_authorization_code_grant
    params = self.open(auth_url, auth_params)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/data/data/com.termux/files/usr/lib/python3.11/site-packages/gallery_dl/extractor/oauth.py", line 75, in open
    browser = webbrowser.get()
              ^^^^^^^^^^^^^^^^
  File "/data/data/com.termux/files/usr/lib/python3.11/webbrowser.py", line 66, in get
    raise Error("could not locate runnable browser")
webbrowser.Error: could not locate runnable browser
@Kavolc
Copy link
Author

Kavolc commented Apr 23, 2023

Edit: adding "-o browser=" gives url to manually paste it on browser.

gallery-dl oauth:reddit -o browser=

@Kavolc Kavolc closed this as completed Apr 23, 2023
mikf added a commit that referenced this issue Apr 23, 2023
It raises an exception instead of returning None
when no runnable browser is available.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants