-
-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[🚀 Feature]: remove guava from client bindings #12737
Comments
@joerg1985, thank you for creating this issue. We will troubleshoot it as soon as we can. Info for maintainersTriage this issue by using labels.
If information is missing, add a helpful comment and then
If the issue is a question, add the
If the issue is valid but there is no time to troubleshoot it, consider adding the
If the issue requires changes or fixes from an external project (e.g., ChromeDriver, GeckoDriver, MSEdgeDriver, W3C),
add the applicable
After troubleshooting the issue, please add the Thank you! |
Why would we wait for Selenium 5? Once we require Java 11, if we can update syntax and methods and dependencies we should just do it. |
I understand the reasoning, a user might be relying on Selenium providing Guava as a dependency. But I think we can tell them what to do in the release notes. |
Okay, this will be a breaking change:
|
Do we allow the native Java interface, or would we need to create a separate implementation for it. I'm hoping to pull it out of core Selenium code entirely for Selenium 5, so maybe we don't need to touch it and can spin it off at that time. |
It should be working fine with the native java interface. |
I just pushed a commit (42cc355) to remove the usage of guava from the browser bindings. These are left areas are left:
|
@joerg1985 I'm going to remove the milestone on this one since there's no need for a specific timeframe on it. Are you planning to continue working on this? Thanks. |
Having a single issue for this is helpful but not so actionable. @joerg1985, if you have identified where we can make code changes, I suggest creating an issue for each place you found and adding instructions for the implementation details. With that, anyone could jump in and help. Then, closing this issue. |
Yes i have planned to work on this as soon as possible. I think i will continue after christmas. I will split this in multiple tasks the next days. |
Okay, i had a look and there is not much left, but there is one question how to remove the use of I would suggest to create two enums to replace them |
I'm pretty much ok with anything that doesn't require users to change their code. 😂 |
I just created the |
I don't have a strong opinion. I believe we can have those enums, and hopefully documenting in the code why we have them. Thanks! |
@diemol @titusfortner i have just pushed a commit to replace most of the usages, these tasks are left:
Have to create the tickets to replace these usages the next days. |
Ok i was not able to describe all changes to remove the So i ended in creating a PR with it, sorry for this ;) |
Use of guava in |
Hey @joerg1985 what is the status? @diemol should we need to announce that we will be removing guava support for a specific release? Not sure the right way to communicate this. |
I don't think so, we should not be exposing Guava functionality. |
@titusfortner still waiting for the review of #13308 by @shs96c After the PR the is merged there is only one use of guava left (the breaking change in |
Alternative option... We don't import Support package by default with selenium-java and keep the guava dependency in that package? Or is that a Selenium 5 level change? :) |
Yes, but if someone is using Selenium they have guava as a transitive dependency. They may be using it without having an explicit dependency, so updating Selenium will cause their code to break. I don't know if that should be called out ahead of time, or just part of the release notes. |
In my personal opinion transitive dependencies should not be something that end users should rely on because they are being brought in as transitive dependencies to solve some programming ask by selenium. Selenium would be free to make any changes to how those functionalities are delivered and in the process it should also be able to add/remove any dependencies that it needs. An end user project that requires guava should explicitly depend on it and not rely on transitive dependencies (Which is always prone to issues especially if one has multiple libraries that bring in multiple versions of the same library, and thus causing dependency conflicts) |
@diemol @titusfortner Now is only one use of guava left is the breaking change in |
Is there a PR for it? |
No, i did not know how to proper document this breaking change in the release notes. |
I remember now. We need to write a blog post about it, announce it, and then make the change because we cannot just deprecate the interface or do something similar. |
In the end, this helps users because there have been countless issues of people reporting dependency conflicts. |
Feature and motivation
When using Java 11 we should not need the guava library in the client bindings not realy, we can do some small changes to remove them. Removing them from the dependencies should be done with Selenium 5, as client code could relay on it on the class path. We might be able to remove it from the server too, but this must be evaluated and could be done later.
Usage example
Less dependencies are in general better.
The text was updated successfully, but these errors were encountered: