ClericPy / ichrome

Chrome controller for Humans, based on Chrome Devtools Protocol(CDP) and python3.7+.
https://pypi.org/project/ichrome/
MIT License
227 stars 29 forks source link

DEBUG:torequests:Retry 0 times failed again: Cannot connect to host 127.0.0.1:9222 ssl:default [Connect call failed ('127.0.0.1', 9222)]. #126

Closed juanfrilla closed 1 year ago

juanfrilla commented 1 year ago

Im combining with scrapy and receiving the following error: DEBUG:torequests:Retry 0 times failed again: Cannot connect to host 127.0.0.1:9222 ssl:default [Connect call failed ('127.0.0.1', 9222)]. Im doing this:

  async def navigate_ichrome(self, doc_id):
      proxy = get_proxy().get("http")
      async with AsyncChromeDaemon(headless=True, proxy=proxy) as cd:
          async with cd.incognito_tab(proxyServer=proxy) as tab:
              await tab.goto(self.origin + "/document/" + doc_id, timeout=60000)
              sleep(30)
              return await tab.html