# To execute this docker-compose yml file use `docker-compose -f <file_name> up` # Add the `-d` flag at the end for detached execution version:"3" services: chrome: image:selenium/standalone-chrome volumes: -/dev/shm:/dev/shm
PS > docker-compose up selenium-standalone_app_1 is up-to-date selenium-standalone_chrome_1 is up-to-date Attaching to selenium-standalone_app_1, selenium-standalone_chrome_1 chrome_1 | 2020-04-1803:04:17,638 INFO Included extra file "/etc/supervisor/conf.d/selenium.conf" during parsing chrome_1 | 2020-04-1803:04:17,639 INFO supervisord started with pid 7 chrome_1 | 2020-04-1803:04:18,641 INFO spawned: 'xvfb' with pid 10 chrome_1 | 2020-04-1803:04:18,642 INFO spawned: 'selenium-standalone' with pid 11 chrome_1 | 03:04:18.800 INFO [GridLauncherV3.parse] - Selenium server version: 3.141.59, revision: e82be7d358 chrome_1 | 2020-04-1803:04:18,801 INFO success: xvfb entered RUNNING state, process has stayed up for > than 0 seconds (startsecs) chrome_1 | 2020-04-1803:04:18,801 INFO success: selenium-standalone entered RUNNING state, process has stayed up for > than 0 seconds (startsecs) chrome_1 | 03:04:18.859 INFO [GridLauncherV3.lambda$buildLaunchers$3] - Launching a standalone Selenium Server on port 4444 chrome_1 | 2020-04-1803:04:18.888:INFO::main: Logging initialized @240ms to org.seleniumhq.jetty9.util.log.StdErrLog chrome_1 | 03:04:19.041 INFO [WebDriverServlet.<init>] - Initialising WebDriverServlet chrome_1 | 03:04:19.122 INFO [SeleniumServer.boot] - Selenium Server is up and running on port 4444 chrome_1 | 03:05:29.991 INFO [ActiveSessionFactory.apply] - Capabilities are: { chrome_1 | "browserName": "chrome", chrome_1 | "version": "" chrome_1 | } chrome_1 | 03:05:29.993 INFO [ActiveSessionFactory.lambda$apply$11] - Matched factory org.openqa.selenium.grid.session.remote.ServicedSession$Factory (provider: org.openqa.selenium.chrome.ChromeDriverService) chrome_1 | Starting ChromeDriver 81.0.4044.69 (6813546031a4bc83f717a2ef7cd4ac6ec1199132-refs/branch-heads/4044@{#776}) on port 27205 chrome_1 | Only local connections are allowed. chrome_1 | Please protect ports used by ChromeDriver and related test frameworks to prevent access by malicious code. chrome_1 | [1587179130.011][SEVERE]: bind() failed: Cannot assign requested address (99) chrome_1 | 03:05:30.539 INFO [ProtocolHandshake.createSession] - Detected dialect: W3C chrome_1 | 03:05:30.563 INFO [RemoteSession$Factory.lambda$performHandshake$0] - Started new session c7eb56f1ed116e861a77db2cbb3acd33 (org.openqa.selenium.chrome.ChromeDriverService) chrome_1 | 03:05:31.362 INFO [ActiveSessions$1.onStop] - Removing session c7eb56f1ed116e861a77db2cbb3acd33 (org.openqa.selenium.chrome.ChromeDriverService)
Traceback (most recent call last): File "test_code.py", line 16, in <module> test_access(driver) File "/usr/local/lib/python3.8/site-packages/selenium/webdriver/remote/webdriver.py", line 170, in __exit__ self.quit() File "/usr/local/lib/python3.8/site-packages/selenium/webdriver/remote/webdriver.py", line 698, in quit self.execute(Command.QUIT) File "/usr/local/lib/python3.8/site-packages/selenium/webdriver/remote/webdriver.py", line 321, in execute self.error_handler.check_response(response) File "/usr/local/lib/python3.8/site-packages/selenium/webdriver/remote/errorhandler.py", line 242, in check_response raise exception_class(message, screen, stacktrace) selenium.common.exceptions.WebDriverException: Message: No active session with ID d0110743cd1a9b2d4789ad493a9c805b