TeslaServiceManualScraper icon indicating copy to clipboard operation
TeslaServiceManualScraper copied to clipboard

indexerror (already downgraded to selenium 4.2.0

Open jlindsey16 opened this issue 4 years ago • 1 comments

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>

jlindsey16 avatar Jul 22 '22 15:07 jlindsey16

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

waywayup1234 avatar May 19 '23 19:05 waywayup1234