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

indexerror (already downgraded to selenium 4.2.0 #13

Open
jlindsey16 opened this issue Jul 22, 2022 · 1 comment
Open

indexerror (already downgraded to selenium 4.2.0 #13

jlindsey16 opened this issue Jul 22, 2022 · 1 comment

Comments

@jlindsey16
Copy link

I am getting this same issue. Launches browser. Populates username. refreshes page. Populates password. submits information. page asks for passcode (2FA), refreshes, says you don't have access to the page and kicks you back to the 2FA, I enter the code, click submit (or wait) and the browser closes.

C:\Users\stone\Downloads\TeslaServiceManualScraper-master\TeslaServiceManualScraper-master>python scrape.py
C:\Users\stone\Downloads\TeslaServiceManualScraper-master\TeslaServiceManualScraper-master\scrape.py:1: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
from distutils.command.clean import clean

DevTools listening on ws://127.0.0.1:53787/devtools/browser/e4778eca-0cef-4c56-9229-57f471a67201
****** SESSION LOADED ******
[7332:23804:0722/094217.385:ERROR:device_event_log_impl.cc(214)] [09:42:17.386] USB: usb_device_handle_win.cc:1048 Failed to read descriptor from node connection: A device attached to the system is not functioning. (0x1F)
[7332:23804:0722/094217.395:ERROR:device_event_log_impl.cc(214)] [09:42:17.396] USB: usb_device_handle_win.cc:1048 Failed to read descriptor from node connection: A device attached to the system is not functioning. (0x1F)
Traceback (most recent call last):
File "C:\Users\stone\Downloads\TeslaServiceManualScraper-master\TeslaServiceManualScraper-master\scrape.py", line 273, in
run()
File "C:\Users\stone\Downloads\TeslaServiceManualScraper-master\TeslaServiceManualScraper-master\scrape.py", line 262, in run
driver.get_index()
File "C:\Users\stone\Downloads\TeslaServiceManualScraper-master\TeslaServiceManualScraper-master\scrape.py", line 53, in get_index
window1 = driver.window_handles[1]
IndexError: list index out of range

C:\Users\stone\Downloads\TeslaServiceManualScraper-master\TeslaServiceManualScraper-master>

@waywayup1234
Copy link

got to scrape.py @ line 53
change the index from 1 to 0 for window1 = driver.window_handles[1]. -> window1 = driver.window_handles[0]

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

No branches or pull requests

2 participants