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

Fix selenium/webdriver/chrome version #28

Merged

Conversation

stage-rl
Copy link
Contributor

@stage-rl stage-rl commented Mar 18, 2024

Problem so zavislostou na nejakom starom repe s Chromom. Napr. tuto riesili takisto, odstranit webdrivers gem a aktualizovat selenium

titusfortner/webdrivers#247 (comment)

@jsuchal
Copy link
Member

jsuchal commented Mar 21, 2024

@celuchmarek hmm, zeby stacilo toto? Skusme merge/deploy ci to zacne nieco hlasit.

@stage-rl
Copy link
Contributor Author

No, mohol som napisat, ze mi to neslo teda z vybuildovaneho dockera predtym, a otestoval som si to z dockera po uprave a islo. Tak verim, ze zaberie.

@celuchmarek
Copy link
Member

Super, diky @stage-rl . Mergnem a uvidíme, čo sa stane 😄

@celuchmarek celuchmarek merged commit c7b6444 into slovensko-digital:master Mar 26, 2024
@celuchmarek
Copy link
Member

@stage-rl Takže ty si nedostal takýto error?

root@uvobot-869dd8db74-vrn9p:/app# bundle exec rake uvobot:run
rake aborted!
LoadError: cannot load such file -- selenium-webdriver
/app/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.18.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:27:in `require'
/app/vendor/bundle/ruby/2.7.0/gems/bootsnap-1.18.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:27:in `require'
/app/vendor/bundle/ruby/2.7.0/gems/activesupport-5.2.8.1/lib/active_support/dependencies.rb:291:in `block in require'
/app/vendor/bundle/ruby/2.7.0/gems/activesupport-5.2.8.1/lib/active_support/dependencies.rb:257:in `load_dependency'
/app/vendor/bundle/ruby/2.7.0/gems/activesupport-5.2.8.1/lib/active_support/dependencies.rb:291:in `require'
/app/lib/uvobot/uvo_scraper.rb:3:in `<main>'
/app/lib/uvobot.rb:2:in `require_relative'
/app/lib/uvobot.rb:2:in `<main>'
/app/lib/tasks/uvobot.rake:5:in `require_relative'
/app/lib/tasks/uvobot.rake:5:in `block (2 levels) in <main>'
/app/vendor/bundle/ruby/2.7.0/gems/rake-13.1.0/exe/rake:27:in `<top (required)>'
/usr/local/bin/bundle:23:in `load'
/usr/local/bin/bundle:23:in `<main>'
Tasks: TOP => uvobot:run
(See full trace by running task with --trace)

Po pridaní selenium-webdriver do Gemfile zase:

2024-03-26 15:16:54 WARN Selenium applicable driver not found; attempting to install with Selenium Manager
rake aborted!
Selenium::WebDriver::Error::WebDriverError: Unable to locate the chromedriver executable; for more information on how to install drivers, see https://www.selenium.dev/documentation/webdriver/getting_started/install_drivers/
/app/vendor/bundle/ruby/2.7.0/gems/selenium-webdriver-4.9.0/lib/selenium/webdriver/common/driver_finder.rb:36:in `path'
/app/vendor/bundle/ruby/2.7.0/gems/selenium-webdriver-4.9.0/lib/selenium/webdriver/common/local_driver.rb:49:in `process_options'
/app/vendor/bundle/ruby/2.7.0/gems/selenium-webdriver-4.9.0/lib/selenium/webdriver/common/local_driver.rb:27:in `initialize_local_driver'
/app/vendor/bundle/ruby/2.7.0/gems/selenium-webdriver-4.9.0/lib/selenium/webdriver/chrome/driver.rb:34:in `initialize'
/app/vendor/bundle/ruby/2.7.0/gems/selenium-webdriver-4.9.0/lib/selenium/webdriver/common/driver.rb:47:in `new'
/app/vendor/bundle/ruby/2.7.0/gems/selenium-webdriver-4.9.0/lib/selenium/webdriver/common/driver.rb:47:in `for'
/app/lib/uvobot/uvo_scraper.rb:22:in `initialize'
/app/lib/tasks/uvobot.rake:29:in `new'
/app/lib/tasks/uvobot.rake:29:in `block (2 levels) in <main>'
/app/vendor/bundle/ruby/2.7.0/gems/rake-13.1.0/exe/rake:27:in `<top (required)>'
/usr/local/bin/bundle:23:in `load'
/usr/local/bin/bundle:23:in `<main>'
Tasks: TOP => uvobot:run
(See full trace by running task with --trace)
2024-03-26 15:16:56 WARN Selenium Unable obtain driver using Selenium Manager
 Unsuccessful command executed: ["/app/vendor/bundle/ruby/2.7.0/gems/selenium-webdriver-4.9.0/bin/linux/selenium-manager", "--browser", "chrome", "--output", "json"]
The chromedriver version cannot be discovered

@stage-rl
Copy link
Contributor Author

stage-rl commented Mar 26, 2024

U mna napr. dnes takto:

bundle exec rake uvobot:run
Dnes som nenašiel žiadne nové IT zákazky.

A to mas z toho dockera?

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

Successfully merging this pull request may close these issues.

3 participants