Second-Hand-Friends / kleinanzeigen-bot

A dilligent command line tool to publish ads on kleinanzeigen.de
GNU Affero General Public License v3.0
188 stars 43 forks source link

[BUG] Failed to connect to browser #315

Open apeltzer opened 1 month ago

apeltzer commented 1 month ago

✔️ Expected Behaviour

Connecting to Chrome works on OSX

🐞 Actual Behaviour

[ERROR] Exception:

            Failed to connect to browser
            ---------------------
            One of the causes could be when you are running as root.
            In that case you need to pass no_sandbox=True

📋 Steps to Reproduce

PDM or executable version, not running the app as root at all - so this should be t he problem.

📺 What browsers are you seeing the problem on? (if applicable)

Chrome

💻 What operating systems are you seeing the problem on? (if applicable)

MacOS

📃 Relevant log output (if applicable)

[ERROR] Exception:

            Failed to connect to browser
            ---------------------
            One of the causes could be when you are running as root.
            In that case you need to pass no_sandbox=True

Code of Conduct

Vel-San commented 1 month ago

FYI A quick fix for this is to open Chrome in debugging mode as well.

Chrome Launch from Terminal

open -a "Google Chrome" --args --remote-debugging-port=9222

Bot Config

arguments: ["-no-sandbox", "--remote-debugging-port=9222"]

benjidea commented 3 weeks ago

Same error for me too. I have tried Chrome and Edge. It seems like the script aborts too quickly to wait for the browser. Maybe it would be a possibility to make the timeout customizable in the config?

The suggested QuickFix has no success either.