Skip to content
CodeKruPro

Read the GitHub Actions log: what is the fix?

QuizEasyAsked in: Capgemini, Google, Salesforce, TCS, Zupee

Read the log.

job.log

Run pytest tests/
ImportError while loading conftest '/home/runner/work/shop/shop/tests/conftest.py'.
tests/conftest.py:2: in <module>
    from selenium import webdriver
E   ModuleNotFoundError: No module named 'selenium'
Error: Process completed with exit code 4.

What is the most likely fix?

  • Install the dependencies in the job (pip install -r requirements.txt) before running pytest, and make sure selenium is listed there
  • Fix a locator in the tests
  • Upgrade Chrome on the runner
  • Increase the job timeout

This question is part of Pro+

Pro+ opens every question in Interview Prep and the mock interview. Every article and the first 2 questions of each topic stay free. Hands-on Selenium and API tasks follow their course lesson's own lock.

See Pro+

Already have Pro+? Sign in