-
-
Notifications
You must be signed in to change notification settings - Fork 8k
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
[dotnet] support installing temporary addon in Firefox #10093
Conversation
Kudos, SonarCloud Quality Gate passed! |
byte[] addOnBytes = File.ReadAllBytes(addOnFileToInstall); | ||
string base64AddOn = Convert.ToBase64String(addOnBytes); | ||
this.InstallAddOn(base64AddOn); | ||
this.InstallAddOn(base64AddOn, temporary); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In reading #8357 (comment) it sounds like geckodriver supports local "unpacked" extensions (if the temporary flag is set) and in that case we'd need to use the "path" parametered api in that case. Ideally we'd check to see if the path is a directory and if so, use that api, otherwise base64 up the file like we are doing now and use the AddOn api.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The API will be a method that takes a path, and a method that takes a path and a temporary value. The implementation of it doesn't matter to the end user.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with you that it will all work fine so long as path
is the path to a .xpi or .zip but not when it is the path to an unpacked extension directory, which it would also be nice to support.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We'll do everything with addon keyword instead of path, so it will work the way you need. It should already work properly with .NET in 4.1, just without the temporary toggle.
merged this instead 1b20938 |
This fixes #10084
Jim, I think this is correct, but let me know if I missed something. Thanks