Skip to content

[java] Set remote active protocol to BiDi for Firefox #15224

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Apr 23, 2025

Conversation

pujagani
Copy link
Contributor

@pujagani pujagani commented Feb 3, 2025

User description

Thanks for contributing to Selenium!
A PR well described will help maintainers to quickly review and merge it

Before submitting your PR, please check our contributing guidelines.
Avoid large PRs, help reviewers by making them as simple and short as possible.

Motivation and Context

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • I have read the contributing document.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

PR Type

Enhancement


Description

  • Set Firefox remote active protocol to BiDi only

  • Updated FirefoxOptions to use BiDi protocol by default


Changes walkthrough 📝

Relevant files
Enhancement
FirefoxOptions.java
Default FirefoxOptions to BiDi protocol only                         

java/src/org/openqa/selenium/firefox/FirefoxOptions.java

  • Changed the remote.active-protocols preference from 3 (CDP+BiDi) to 1
    (BiDi only)
  • Updated inline comments to reflect BiDi-only support
  • +2/-3     

    Need help?
  • Type /help how to ... in the comments thread for any questions about Qodo Merge usage.
  • Check out the documentation for more information.
  • @pujagani pujagani marked this pull request as ready for review April 22, 2025 11:13
    Copy link
    Contributor

    PR Reviewer Guide 🔍

    Here are some key observations to aid the review process:

    ⏱️ Estimated effort to review: 1 🔵⚪⚪⚪⚪
    🧪 No relevant tests
    🔒 No security concerns identified
    ⚡ Recommended focus areas for review

    Breaking Change

    This change switches Firefox from supporting both CDP and BiDi protocols (value 3) to BiDi only (value 1). This is a breaking change that could affect users relying on CDP functionality with Firefox.

      addPreference("remote.active-protocols", 1);
    }

    Copy link
    Contributor

    qodo-merge-pro bot commented Apr 22, 2025

    PR Code Suggestions ✨

    No code suggestions found for the PR.

    @titusfortner
    Copy link
    Member

    Curious what this is doing/why it is needed?

    @pujagani
    Copy link
    Contributor Author

    pujagani commented Apr 23, 2025

    We had set the active protocol to 3, which supports both BiDi and CDP while CDP was being deprecated. But now that CDP support in Firefox is removed and Selenium has removed the support too, we want to switch to the default protocol, which supports only BiDi. We need to do it for all languages, but I was trying with Java first to see if I wasn't breaking anything.

    @pujagani pujagani merged commit 019f7c5 into SeleniumHQ:trunk Apr 23, 2025
    32 checks passed
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Projects
    None yet
    Development

    Successfully merging this pull request may close these issues.

    2 participants