質問失礼いたします。pythonでスクレイピングを試みたときに出たエラーを解決できずにいます。
原因も対処方法も検討が付かずどうしたらいいか分からない状態です。
恐れ入りますが、このエラーの原因と解決方法をご教授いただきたいです。よろしくお願い申し上げます。
python
1from selenium import webdriver 2import time 3import pandas as pd 4 5USER = "test_user" 6PASS = "test_pw" 7 8from selenium.webdriver.chrome import service as fs 9 10# ドライバー指定でChromeブラウザを開く 11chrome_service = fs.Service(executable_path='C:\Users\Owner\Desktop\Mypandas\chromedriver.exe') 12browser = webdriver.Chrome(service=chrome_service) 13browser.implicitly_wait(3) 14 15url_login = "https://kino-code.work/" 16browser.get(url_login) 17time.sleep(3) 18print("ログインしました") 19 20 21WebDriverException Traceback (most recent call last) 22~\AppData\Local\Temp/ipykernel_17004/4102995843.py in <module> 23 1 url_login = "https://kino-code.work/" 24----> 2 browser.get(url_login) 25 3 time.sleep(3) 26 4 print("ログインしました") 27 28~\anaconda3\lib\site-packages\selenium\webdriver\remote\webdriver.py in get(self, url) 29 434 Loads a web page in the current browser session. 30 435 """ 31--> 436 self.execute(Command.GET, {'url': url}) 32 437 33 438 @property 34 35~\anaconda3\lib\site-packages\selenium\webdriver\remote\webdriver.py in execute(self, driver_command, params) 36 422 response = self.command_executor.execute(driver_command, params) 37 423 if response: 38--> 424 self.error_handler.check_response(response) 39 425 response['value'] = self._unwrap_value( 40 426 response.get('value', None)) 41 42~\anaconda3\lib\site-packages\selenium\webdriver\remote\errorhandler.py in check_response(self, response) 43 245 alert_text = value['alert'].get('text') 44 246 raise exception_class(message, screen, stacktrace, alert_text) # type: ignore[call-arg] # mypy is not smart enough here 45--> 247 raise exception_class(message, screen, stacktrace) 46 248 47 249 def _value_or_default(self, obj: Mapping[_KT, _VT], key: _KT, default: _VT) -> _VT: 48 49WebDriverException: Message: chrome not reachable 50 (Session info: chrome=96.0.4664.110) 51Stacktrace: 52Backtrace: 53 Ordinal0 [0x007E6903+2517251] 54 Ordinal0 [0x0077F8E1+2095329] 55 Ordinal0 [0x00682710+1058576] 56 Ordinal0 [0x006776A4+1013412] 57 Ordinal0 [0x00677EA8+1015464] 58 Ordinal0 [0x00679695+1021589] 59 Ordinal0 [0x00673686+996998] 60 Ordinal0 [0x00683A60+1063520] 61 Ordinal0 [0x006D5382+1397634] 62 Ordinal0 [0x006C639B+1336219] 63 Ordinal0 [0x006A27A7+1189799] 64 Ordinal0 [0x006A3609+1193481] 65 GetHandleVerifier [0x00975904+1577972] 66 GetHandleVerifier [0x00A20B97+2279047] 67 GetHandleVerifier [0x00876D09+534521] 68 GetHandleVerifier [0x00875DB9+530601] 69 Ordinal0 [0x00784FF9+2117625] 70 Ordinal0 [0x007898A8+2136232] 71 Ordinal0 [0x007899E2+2136546] 72 Ordinal0 [0x00793541+2176321] 73 BaseThreadInitThunk [0x75906739+25] 74 RtlGetFullPathName_UEx [0x77098AFF+1215] 75 RtlGetFullPathName_UEx [0x77098ACD+1165]
あなたの回答
tips
プレビュー