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

Fixing chromedriver install for distros that uses AUR #404

Closed
wants to merge 1 commit into from
Closed

Fixing chromedriver install for distros that uses AUR #404

wants to merge 1 commit into from

Conversation

hntirgeam
Copy link

When installing google-chrome from AUR using pacman path to command is /usr/bin/google-chrome-stable.

This causes an FileNotFoundError in the download_driver function.

This PR fixes it.

Reference: https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=google-chrome

install -m755 google-chrome-$_channel.sh "$pkgdir"/usr/bin/google-chrome-$_channel

…installable links to google-chrome-stable, not to google-chrome)
@MShawon
Copy link
Owner

MShawon commented Jul 24, 2022

It seems google-chrome-stable command is available on every linux distro.. future release will replace google-chrome to google-chrome-stable

@ngewa
Copy link

ngewa commented Jul 31, 2022

Getting Chrome Driver...
Traceback (most recent call last):
File "youtube_viewer.py", line 728, in
osname, exe_name = download_driver(patched_drivers=patched_drivers)
File "/root/Ultimate-YouTube-Viewer/youtubeviewer/download_driver.py", line 25, in download_driver
with subprocess.Popen(['google-chrome', '--version'], stdout=subprocess.PIPE) as proc:
File "/usr/lib/python3.8/subprocess.py", line 858, in init
self._execute_child(args, executable, preexec_fn, close_fds,
File "/usr/lib/python3.8/subprocess.py", line 1704, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'google-chrome'
root@Server-V2:~/Ultimate-YouTube-Viewer#

@MShawon
Copy link
Owner

MShawon commented Aug 5, 2022

@ngewa install google chrome first

@orangejuicy-creator
Copy link

[93mGetting Chrome Driver...�[0m
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/urllib/request.py", line 1346, in do_open
h.request(req.get_method(), req.selector, req.data, headers,
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/http/client.py", line 1285, in request
self._send_request(method, url, body, headers, encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/http/client.py", line 1331, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/http/client.py", line 1280, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/http/client.py", line 1040, in _send_output
self.send(msg)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/http/client.py", line 980, in send
self.connect()
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/http/client.py", line 1454, in connect
self.sock = self._context.wrap_socket(self.sock,
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/ssl.py", line 500, in wrap_socket
return self.sslsocket_class._create(
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/ssl.py", line 1040, in _create
self.do_handshake()
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/ssl.py", line 1309, in do_handshake
self._sslobj.do_handshake()
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Users/mac/Downloads/YouTube-Viewer-master/youtube_viewer.py", line 933, in
osname, exe_name = download_driver(patched_drivers=patched_drivers)
File "/Users/mac/Downloads/YouTube-Viewer-master/youtubeviewer/download_driver.py", line 112, in download_driver
uc.install()
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/undetected_chromedriver/_compat.py", line 259, in install
ChromeDriverManager(executable_path, target_version, *args, **kwargs).install()
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/undetected_chromedriver/_compat.py", line 189, in install
self.fetch_chromedriver()
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/undetected_chromedriver/_compat.py", line 218, in fetch_chromedriver
ver = self.get_release_version_number().vstring
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/undetected_chromedriver/_compat.py", line 208, in get_release_version_number
return LooseVersion(urlopen(self.class.DL_BASE + path).read().decode())
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/urllib/request.py", line 214, in urlopen
return opener.open(url, data, timeout)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/urllib/request.py", line 517, in open
response = self._open(req, data)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/urllib/request.py", line 534, in _open
result = self._call_chain(self.handle_open, protocol, protocol +
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/urllib/request.py", line 494, in _call_chain
result = func(*args)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/urllib/request.py", line 1389, in https_open
return self.do_open(http.client.HTTPSConnection, req,
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/urllib/request.py", line 1349, in do_open
raise URLError(err)
urllib.error.URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129)>

@MShawon MShawon closed this in f0fe93d Sep 25, 2022
@pupheng
Copy link

pupheng commented Sep 27, 2022

may you add new auto login gmail account into each thread that we're running?

@hntirgeam hntirgeam deleted the fix_chromedriver_install_aur branch September 27, 2022 23:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants