pythonselenium-webdriver

How do I retrieve the version of Selenium currently installed, from Python?


How can I programmatically get the version of Selenium I have installed in my Python environment?


Solution

  • As simply as

    >>> import selenium
    >>> selenium.__version__
    '2.37.2'
    

    or for command line:

    $ python -c "import selenium; print(selenium.__version__)"
    2.37.2