botasaurus
botasaurus copied to clipboard
Browser Visible Mode Doesn't Work: ECONNREFUSED
result = run_parallel(run, used_data, n) at wrapper_browser (/home/user/.local/lib/python3.10/site-packages/botasaurus/decorators.py:664) parallel_thread.join(0.2) # time out not to block KeyboardInterrupt at run_parallel (/home/user/.local/lib/python3.10/site-packages/botasaurus/decorators.py:166) raise self._exception at join (/home/user/.local/lib/python3.10/site-packages/botasaurus/decorators.py:152) self.result = target(*args, **kwargs) at function (/home/user/.local/lib/python3.10/site-packages/botasaurus/decorators.py:143) return Parallel(n_jobs=n_workers, backend="threading")( at execute_parallel_tasks (/home/user/.local/lib/python3.10/site-packages/botasaurus/decorators.py:158) return output if self.return_generator else list(output) at call (/home/user/.local/lib/python3.10/site-packages/joblib/parallel.py:1952) yield from self._retrieve() at _get_outputs (/home/user/.local/lib/python3.10/site-packages/joblib/parallel.py:1595) self._raise_error_fast() at _retrieve (/home/user/.local/lib/python3.10/site-packages/joblib/parallel.py:1699) error_job.get_result(self.timeout) at _raise_error_fast (/home/user/.local/lib/python3.10/site-packages/joblib/parallel.py:1734) return self._return_or_raise() at get_result (/home/user/.local/lib/python3.10/site-packages/joblib/parallel.py:736) raise self._result at _return_or_raise (/home/user/.local/lib/python3.10/site-packages/joblib/parallel.py:754)
... across the bridge ...
at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1605:16) Error: connect ECONNREFUSED 127.0.0.1:38387
^ 🌉 Error: connect ECONNREFUSED 127.0.0.1:38387
Keep getting this error with headless=False, this is the config: @browser(window_size=bt.WindowSize.REAL,parallel=8, create_driver=create_stealth_driver( start_url=lambda data: data["link"], wait=12 ), add_arguments=add_arguments, raise_exception=True, headless=False, keep_drivers_alive=True, cache=True, output=None, reuse_driver=True, block_resources=True, block_images=True, max_retry=10 )
works fine with Headless=False, using these arguments: def add_arguments(data, options): options.add_argument('--disable-dev-shm-usage') options.add_argument('--no-sandbox') options.add_argument('--server') options.add_argument('--disable-setuid-sandbox') options.add_argument('--no-zygote') options.add_argument('--disable-gpu-sandbox') options.add_argument('--disable-software-rasterizer') options.add_argument('--ignore-certificate-errors') options.add_argument('--ignore-ssl-errors') options.add_argument('--use-gl=swiftshader') options.add_argument('--window-size=1920,1080')
Also tried using only these: def add_arguments(data, options): options.add_argument('--disable-dev-shm-usage') options.add_argument('--no-sandbox') options.add_argument('--server') options.add_argument('--disable-setuid-sandbox')
Tried with both proxy turned on and off, nothing seems to help!
Hello, I had the same problem with the parallel.
Does it work without parallelizing?
Doesn't seem to work in single browser mode too for me. Worked for you? Could you share botasauras version, chrome/chromedriver versions please?
Also, with or without docker? Thanks
@VincentDoreau13
Can you tell me your environment please
I have tried on: Centos 9, Ubuntu 22 and Ubuntu 20 and Debian too. Using in a non-docker setup with Python3 and Chrome,Chrome driver 122
All of these machines majorly on Google Cloud
Same issue here.. No updates about?
@surmatech I've tried on Fedora 37/38/39 too, but it doesn't work. So, I confirm the issue
We have released v4, which solves many bugs and adds awesome feautres like UI Run. I suggest using it and let me know if this issue reoccurs, to do so, please run the following commands:
python -m pip install bota botasaurus_api botasaurus_driver bota botasaurus-proxy-authentication botasaurus_server --upgrade
Then read the documentation at https://github.com/omkarcloud/botasaurus.