title: How can I get Selenium tests to run in python with Github actions?
body: <p>I'm having trouble getting my python Selenium running in github actions.</p>
  
  <p>I have been using Circle CI for the past year, but recently began migrating over to github actions.</p>
  
  <p>For Circle CI to run selenium in a chrome browser, I had the following lines in my config.yml:</p>
  
  <pre><code>docker:
      # includes chrome browser for selenium testing
    - image: circleci/python:3.7.4-browsers
  </code></pre>
  
  <p>and there didn't seem to be a need to install a chromedriver.</p>
  
  <p>I am using the following in my githubs action .yml file:</p>
  
  <pre><code>jobs:
    build:
      runs-on: ubuntu-latest
      services:
        selenium:
          image: selenium/standalone-chrome
      steps:
      - uses: actions/checkout@v1
      - name: Set up Python 3.7
        uses: actions/setup-python@v1
        with:
          python-version: 3.7
      - name: Install dependencies
        run: |
          python -m pip install --upgrade pip
          pip install pipenv
          pipenv install
      - name: Prepare Selenium
        # https://github.com/marketplace/actions/setup-chromedriver
        uses: nanasess/setup-chromedriver@master
      - name: Launch browser
        run: |
          google-chrome --version
          export DISPLAY=:99
          chromedriver --url-base=/wd/hub &amp;
          sudo Xvfb -ac :99 -screen 0 1280x1024x24 &gt; /dev/null 2&gt;&amp;1 &amp; # optional, disables headless mode
      - name: Run tests
        run: pipenv run python manage.py test functional_tests.tests.test_selenium.test_exams -v 2
  </code></pre>
  
  <p>But I get the following error when in my python code I try to run: </p>
  
  <pre><code>from selenium import webdriver
  driver = webdriver.Chrome()
  </code></pre>
  
  <pre><code>  File "/home/runner/.local/share/virtualenvs/lang-EMCZ4oUT/lib/python3.7/site-packages/selenium/webdriver/chrome/webdriver.py", line 81, in __init__
      desired_capabilities=desired_capabilities)
    File "/home/runner/.local/share/virtualenvs/lang-EMCZ4oUT/lib/python3.7/site-packages/selenium/webdriver/remote/webdriver.py", line 157, in __init__
      self.start_session(capabilities, browser_profile)
    File "/home/runner/.local/share/virtualenvs/lang-EMCZ4oUT/lib/python3.7/site-packages/selenium/webdriver/remote/webdriver.py", line 252, in start_session
      response = self.execute(Command.NEW_SESSION, parameters)
    File "/home/runner/.local/share/virtualenvs/lang-EMCZ4oUT/lib/python3.7/site-packages/selenium/webdriver/remote/webdriver.py", line 321, in execute
      self.error_handler.check_response(response)
    File "/home/runner/.local/share/virtualenvs/lang-EMCZ4oUT/lib/python3.7/site-packages/selenium/webdriver/remote/errorhandler.py", line 242, in check_response
      raise exception_class(message, screen, stacktrace)
  selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: exited abnormally.
    (unknown error: DevToolsActivePort file doesn't exist)
    (The process started from chrome location /usr/bin/google-chrome is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
  </code></pre>
  
  <p>From what I can read online, I should need just the <code>uses: nanasess/setup-chromedriver@master</code> and shouldn't need <code>image: selenium/standalone-chrome</code>, but switching either in or out doesn't make any difference, the python tests still cannot find chrome browser.</p>
  
  <p>Am I supposed to set up a port to listen to?</p>