3

When I run, it shows the result as I expected but there's error in consol. Why I face this?

word = '5702016617610'
chromeoptions = webdriver.ChromeOptions()
chromeoptions.set_headless
driver = webdriver.Chrome(executable_path=r"C:\0_MINSU\PythonWorksapce\chromedriver.exe", 
                           options=chromeoptions)
driver.get(f"https://www.lotteon.com/p/product/LM{word}")
url = driver.page_source

soup = BeautifulSoup(url, 'lxml')
content = soup.find("div", {"class":"price"})
if content:
    content=print(content.text)
else:
     print("NO INFORMATION")

Console Output:

C:\0_MINSU\PythonWorksapce>[14360:ShellIpcClient] simple_message_loop.cc:120:Run Run called on MessageLoop that's already been Quit!
C:/Users/lemi7005/AppData/Local/Programs/Python/Python39/python.exe c:/0_MINSU/PythonWorksapce/lotte.py
c:\0_MINSU\PythonWorksapce\lotte.py:198: DeprecationWarning: use options instead of chrome_options
  driver = webdriver.Chrome(executable_path=r"C:\0_MINSU\PythonWorksapce\chromedriver.exe",

DevTools listening on ws://127.0.0.1:64816/devtools/browser/97041e93-fff1-4414-a6bf-a96096b4ce0a
[16412:9944:0322/174352.276:ERROR:device_event_log_impl.cc(214)] [17:43:52.278] USB: usb_device_handle_win.cc:1056 Failed to read descriptor from node connection: A device attached to the system is not functioning. (0x1F)
[16412:9944:0322/174352.276:ERROR:device_event_log_impl.cc(214)] [17:43:52.280] USB: usb_device_handle_win.cc:1056 Failed to read descriptor from node connection: A device attached to the system is not functioning. (0x1F)
 64,900
            원

If I run it as the result is 'NO INFORMATION', then I also face similar output:

DevTools listening on ws://127.0.0.1:65176/devtools/browser/f5d6f24a-b697-476e-950a-48befa6aa30f
NO INFORMATION
[10236:18192:0322/175011.139:ERROR:device_event_log_impl.cc(214)] [17:50:11.139] USB: usb_device_handle_win.cc:1056 Failed to read descriptor from node connection: A device attached to the system is not functioning. (0x1F)
Minsu Lee
  • 31
  • 1
  • 1
  • 2
  • 1
    that is a known issue and probably can be ignored. See this answer https://stackoverflow.com/questions/65080685/usb-usb-device-handle-win-cc1020-failed-to-read-descriptor-from-node-connectio – user3732793 Mar 22 '21 at 13:53
  • I want to save the result in excel. In this case, I also can ignore this...? – Minsu Lee Mar 22 '21 at 14:39
  • It has to do with the Chomium Driver who collects the data not with your result. Probably will fade away with a newer version when available – user3732793 Mar 23 '21 at 15:07

0 Answers0