{"id":3793,"library":"robotframework-seleniumlibrary","title":"SeleniumLibrary","description":"SeleniumLibrary is a web testing library for Robot Framework, leveraging the Selenium WebDriver internally. It supports robust browser automation for web application testing. The current version, 6.8.0, supports Python 3.8 through 3.14, various Selenium 4.x versions, and Robot Framework 6.1.1 through 7.3.2. Releases are frequent, typically adapting to new Python, Selenium, and Robot Framework versions.","status":"active","version":"6.8.0","language":"en","source_language":"en","source_url":"https://github.com/robotframework/SeleniumLibrary","tags":["web automation","testing","robot framework","selenium","qa"],"install":[{"cmd":"pip install robotframework-seleniumlibrary","lang":"bash","label":"Install latest version"}],"dependencies":[{"reason":"Core dependency for browser automation. Requires Selenium 4.x+","package":"selenium","optional":false},{"reason":"Core dependency for running tests. Requires Robot Framework 6.1.1+ (or 7.x)","package":"robotframework","optional":false},{"reason":"Internal command-line utility dependency, specific version range fixes applied.","package":"click","optional":true}],"imports":[{"note":"SeleniumLibrary is a Robot Framework library, imported directly in the settings section of a .robot file, not as a Python module in Python code.","wrong":"from robotframework.libraries import SeleniumLibrary","symbol":"SeleniumLibrary","correct":"*** Settings ***\nLibrary    SeleniumLibrary"}],"quickstart":{"code":"*** Settings ***\nLibrary    SeleniumLibrary\n\n*** Test Cases ***\nExample Login Test\n    Open Browser    https://the-internet.herokuapp.com/login    browser=chrome\n    Input Text    id=username    ${USERNAME_HERE}\n    Input Text    id=password    ${PASSWORD_HERE}\n    Click Button    css:button[type='submit']\n    Element Should Contain    id=flash    You logged into a secure area!\n    Close Browser","lang":"robotframework","description":"This Robot Framework example demonstrates a basic login test using SeleniumLibrary. It opens a Chrome browser, navigates to a login page, inputs text into username and password fields, clicks the login button, asserts a successful login message, and then closes the browser. Replace `${USERNAME_HERE}` and `${PASSWORD_HERE}` with actual credentials or variables."},"warnings":[{"fix":"Ensure your `selenium` package is updated to version 4.x or newer (e.g., `pip install --upgrade selenium`).","message":"SeleniumLibrary version 6.0.0 and newer requires Selenium WebDriver 4.x+. Older versions of Selenium are no longer supported.","severity":"breaking","affected_versions":">=6.0.0"},{"fix":"Use the `options` argument with Selenium's `Options` object (e.g., `options=chromeoptions:add_argument(--headless)`).","message":"The `headlesschrome` and `headlessfirefox` browser options for `Open Browser` were deprecated and removed in v6.2.0. Headless mode should now be configured using Selenium options directly.","severity":"deprecated","affected_versions":">=6.2.0"},{"fix":"Upgrade SeleniumLibrary to v6.1.1 or newer to ensure compatibility with recent Selenium versions.","message":"SeleniumLibrary v6.1.1 fixed an incompatibility with Selenium v4.10.0+ where certain deprecated Selenium code paths were removed, causing issues for the library.","severity":"gotcha","affected_versions":"6.1.0 (with Selenium >=4.10.0)"},{"fix":"If experiencing dependency resolution issues with `click`, ensure you are on SeleniumLibrary 6.7.1 or newer. You might need to manually downgrade `click` if an incompatible version was installed.","message":"Version 6.7.1 downgraded the requirement on the `click` dependency to `click>=8.0` to address installation issues in some environments.","severity":"gotcha","affected_versions":"6.7.0 (potentially)"},{"fix":"Migrate your test environment and Robot Framework setup to Python 3.8 or newer.","message":"Python 2 support was dropped prior to SeleniumLibrary 4.0. All modern versions require Python 3.8+.","severity":"breaking","affected_versions":"<4.0 (for Python 2 users)"},{"fix":"Update library imports in your Robot Framework `*** Settings ***` and ensure keyword calls reflect the new library name. Refer to migration guides for details.","message":"Prior to version 3.0, the library was known as `Selenium2Library`. Migrating to `SeleniumLibrary` requires changing the import statement (`Library Selenium2Library` to `Library SeleniumLibrary`) and potentially updating keyword calls if prefixed.","severity":"breaking","affected_versions":"<3.0 (for `Selenium2Library` users)"}],"env_vars":null,"last_verified":"2026-04-11T00:00:00.000Z","next_check":"2026-07-10T00:00:00.000Z"}