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

Address Selenium error #17

Open
yahonda opened this issue Aug 15, 2024 · 0 comments
Open

Address Selenium error #17

yahonda opened this issue Aug 15, 2024 · 0 comments

Comments

@yahonda
Copy link
Owner

yahonda commented Aug 15, 2024

Steps to reproduce

  • At multipass host
multipass launch 24.04 --cpus 4 --disk 20G --memory 8G --name rails-dev-box --cloud-init ./cloud-init.yaml --timeout 1200
multipass shell rails-dev-box
  • At multipass guest
git clone https://github.com/rails/rails
cd rails
bundle update --bundler
bundle install
cd actionpack
bin/test

Expected behavior

It should pass.

Actual behavior

$ bin/test
2024-08-15 14:42:06 INFO Selenium [:logger_info] Details on how to use and modify Selenium logger:
  https://selenium.dev/documentation/webdriver/troubleshooting/logging

2024-08-15 14:42:06 ERROR Selenium Exception occurred: Unsuccessful command executed: ["/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/bin/linux/selenium-manager", "--browser", "chrome", "--language-binding", "ruby", "--output", "json"] - Code 2
{}
/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/bin/linux/selenium-manager: 1: Syntax error: "(" unexpected

2024-08-15 14:42:06 ERROR Selenium Backtrace:
	/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/selenium_manager.rb:81:in `run'
	/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/selenium_manager.rb:44:in `binary_paths'
	/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/driver_finder.rb:58:in `paths'
	/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/driver_finder.rb:39:in `driver_path'
	/home/ubuntu/rails/actionpack/lib/action_dispatch/system_testing/browser.rb:77:in `resolve_driver_path'
	/home/ubuntu/rails/actionpack/lib/action_dispatch/system_testing/browser.rb:45:in `preload'
	/home/ubuntu/rails/actionpack/lib/action_dispatch/system_testing/driver.rb:21:in `initialize'
	/home/ubuntu/rails/actionpack/lib/action_dispatch/system_test_case.rb:161:in `new'
	/home/ubuntu/rails/actionpack/lib/action_dispatch/system_test_case.rb:161:in `driven_by'
	/home/ubuntu/rails/actionpack/test/abstract_unit.rb:521:in `<class:DrivenBySeleniumWithChrome>'
	/home/ubuntu/rails/actionpack/test/abstract_unit.rb:520:in `<top (required)>'
	/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	/home/ubuntu/rails/actionpack/test/abstract/callbacks_test.rb:3:in `<top (required)>'
	/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	/home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:62:in `block in load_tests'
	/home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:60:in `each'
	/home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:60:in `load_tests'
	/home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:52:in `run'
	/home/ubuntu/rails/tools/test.rb:18:in `<top (required)>'
	bin/test:5:in `require_relative'
	bin/test:5:in `<main>'
/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/driver_finder.rb:75:in `rescue in paths': Unable to obtain chromedriver; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors/driver_location (Selenium::WebDriver::Error::NoSuchDriverError)
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/driver_finder.rb:49:in `paths'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/driver_finder.rb:39:in `driver_path'
	from /home/ubuntu/rails/actionpack/lib/action_dispatch/system_testing/browser.rb:77:in `resolve_driver_path'
	from /home/ubuntu/rails/actionpack/lib/action_dispatch/system_testing/browser.rb:45:in `preload'
	from /home/ubuntu/rails/actionpack/lib/action_dispatch/system_testing/driver.rb:21:in `initialize'
	from /home/ubuntu/rails/actionpack/lib/action_dispatch/system_test_case.rb:161:in `new'
	from /home/ubuntu/rails/actionpack/lib/action_dispatch/system_test_case.rb:161:in `driven_by'
	from /home/ubuntu/rails/actionpack/test/abstract_unit.rb:521:in `<class:DrivenBySeleniumWithChrome>'
	from /home/ubuntu/rails/actionpack/test/abstract_unit.rb:520:in `<top (required)>'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/ubuntu/rails/actionpack/test/abstract/callbacks_test.rb:3:in `<top (required)>'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:62:in `block in load_tests'
	from /home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:60:in `each'
	from /home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:60:in `load_tests'
	from /home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:52:in `run'
	from /home/ubuntu/rails/tools/test.rb:18:in `<top (required)>'
	from bin/test:5:in `require_relative'
	from bin/test:5:in `<main>'
/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/selenium_manager.rb:81:in `run': Unsuccessful command executed: ["/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/bin/linux/selenium-manager", "--browser", "chrome", "--language-binding", "ruby", "--output", "json"] - Code 2 (Selenium::WebDriver::Error::WebDriverError)
{}
/home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/bin/linux/selenium-manager: 1: Syntax error: "(" unexpected

	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/selenium_manager.rb:44:in `binary_paths'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/driver_finder.rb:58:in `paths'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/selenium-webdriver-4.22.0/lib/selenium/webdriver/common/driver_finder.rb:39:in `driver_path'
	from /home/ubuntu/rails/actionpack/lib/action_dispatch/system_testing/browser.rb:77:in `resolve_driver_path'
	from /home/ubuntu/rails/actionpack/lib/action_dispatch/system_testing/browser.rb:45:in `preload'
	from /home/ubuntu/rails/actionpack/lib/action_dispatch/system_testing/driver.rb:21:in `initialize'
	from /home/ubuntu/rails/actionpack/lib/action_dispatch/system_test_case.rb:161:in `new'
	from /home/ubuntu/rails/actionpack/lib/action_dispatch/system_test_case.rb:161:in `driven_by'
	from /home/ubuntu/rails/actionpack/test/abstract_unit.rb:521:in `<class:DrivenBySeleniumWithChrome>'
	from /home/ubuntu/rails/actionpack/test/abstract_unit.rb:520:in `<top (required)>'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/ubuntu/rails/actionpack/test/abstract/callbacks_test.rb:3:in `<top (required)>'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	from /home/ubuntu/.rbenv/versions/3.3.4/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:62:in `block in load_tests'
	from /home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:60:in `each'
	from /home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:60:in `load_tests'
	from /home/ubuntu/rails/railties/lib/rails/test_unit/runner.rb:52:in `run'
	from /home/ubuntu/rails/tools/test.rb:18:in `<top (required)>'
	from bin/test:5:in `require_relative'
	from bin/test:5:in `<main>'
$
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

1 participant