Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

YouTube.py not loading Firefox binary even if i try setting its absolute path #111

Open
MinervaArgus opened this issue Feb 19, 2025 · 5 comments

Comments

@MinervaArgus
Copy link

Traceback (most recent call last):
File "/mnt/d/MoneyPrinterV2/src/main.py", line 436, in
main()
File "/mnt/d/MoneyPrinterV2/src/main.py", line 132, in main
youtube = YouTube(
File "/mnt/d/MoneyPrinterV2/src/classes/YouTube.py", line 83, in init
self.browser: webdriver.Firefox = webdriver.Firefox(service=self.service, options=self.options)
File "/mnt/d/MoneyPrinterV2/venv/lib/python3.10/site-packages/selenium/webdriver/firefox/webdriver.py", line 71, in init
super().init(command_executor=executor, options=options)
File "/mnt/d/MoneyPrinterV2/venv/lib/python3.10/site-packages/selenium/webdriver/remote/webdriver.py", line 250, in init
self.start_session(capabilities)
File "/mnt/d/MoneyPrinterV2/venv/lib/python3.10/site-packages/selenium/webdriver/remote/webdriver.py", line 342, in start_session
response = self.execute(Command.NEW_SESSION, caps)["value"]
File "/mnt/d/MoneyPrinterV2/venv/lib/python3.10/site-packages/selenium/webdriver/remote/webdriver.py", line 429, in execute
self.error_handler.check_response(response)
File "/mnt/d/MoneyPrinterV2/venv/lib/python3.10/site-packages/selenium/webdriver/remote/errorhandler.py", line 232, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.InvalidArgumentException: Message: binary is not a Firefox executable

@FujiwaraChoki
Copy link
Owner

What is your config?

@MinervaArgus
Copy link
Author

What is your config?

{
"verbose": true,
"firefox_profile": "/mnt/d/profile",
"headless": false,
"twitter_language": "English",
"llm": "gpt4",
"image_prompt_llm": "gpt35_turbo",
"image_model": "prodia",
"threads": 2,
"zip_url": "",
"is_for_kids": false,
"google_maps_scraper": "https://github.com/gosom/google-maps-scraper/archive/refs/tags/v0.9.7.zip",
"email": {
"smtp_server": "smtp.gmail.com",
"smtp_port": 587,
"username": "",
"password": ""
},
"google_maps_scraper_niche": "",
"scraper_timeout": 300,
"outreach_message_subject": "I have a question...",
"outreach_message_body_file": "outreach_message.html",
"assembly_ai_api_key": "",
"font": "bold_font.ttf",
"imagemagick_path": "/mnt/c/'Program Files'/ImageMagick-7.1.1-Q16-HDRI/magick.exe"
}

@MinervaArgus
Copy link
Author

MinervaArgus commented Feb 19, 2025

@FujiwaraChoki

I even tried editing Youtube.py to have this change

self.options.binary_location = r"\\mnt\\c\\'Program Files'\\'Mozilla Firefox'\\firefox.exe"

and it still doesn't work

@FujiwaraChoki
Copy link
Owner

It doesn't seem like you have the correct firefox profile path set.

Is /d/profile a valid firefox profile?

Also, try to use it on a Windows Native Drive, not WSL.

@MinervaArgus
Copy link
Author

MinervaArgus commented Feb 25, 2025

It doesn't seem like you have the correct firefox profile path set.

Is /d/profile a valid firefox profile?

Also, try to use it on a Windows Native Drive, not WSL.

tried it on Windows and i get an error for all of the moviepy imports stating that they werent available from moviepy, /mnt/d/profile is a valid path and is the path to the folder of the profile i made in Firefox specifically for MoneyPrinter

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants