[rb] Implement driver methods for installing and uninstalling web extensions via BiDi - #17879
[rb] Implement driver methods for installing and uninstalling web extensions via BiDi#17879titusfortner wants to merge 7 commits into
Conversation
PR Summary by Qodo[rb] Add cross-browser Driver#install_web_extension / uninstall_web_extension
AI Description
Diagram
High-Level Assessment
Files changed (24)
|
Code Review by Qodo
1.
|
637e3ae to
dfa8d6b
Compare
…Firefox classic install_addon methods
…directory via se/file
…ium's unsupported modes
dfa8d6b to
9e869f9
Compare
Code Review by Qodo
1.
|
|
Code review by qodo was updated up to the latest commit 7e229b9 |
|
Code review by qodo was updated up to the latest commit 3b7ab15 |
…ample, zip_file alias
|
Code review by qodo was updated up to the latest commit bbbfaff |
🔗 Related Issues
Implements accepted ADR #17817 (tracking: #17933) for Ruby.
💥 What does this PR do?
Implements the ADR for the Ruby bindings:
Driver#install_web_extensionandDriver#uninstall_web_extension, backed by thegenerated BiDi
webExtensionprotocol classes. Install accepts a directory, a packed archive, orbase64 bytes (plus Firefox's
permanent/allow_private_browsingoptions) and returns aWebExtensionwrapping the id; uninstall takes that object.moz/addonendpoint), andthe legacy
#install_addon/#uninstall_addonare deprecated toward the new methods — the two namesconverge rather than one routing to the other.
se/fileand referenced by thereturned path, so unpacked-directory installs run on a Grid node, not just locally.
"enable BiDi" error instead of
NoMethodError.on the Grid, over BiDi or the classic endpoint.
archivePathand base64 ([🐛 Bug]: [python][Chrome] Webextension - no support for archived and base64 extensionData type in Chrome? #16541),so those inputs raise
UnsupportedOperationError. Directory installs upload the same way and work on theGrid. No user flags are needed — Chrome 149 dropped the extension-debugging flags earlier builds required.
🔧 Implementation Notes
web_extension_data): a directory is uploaded viase/fileand passed as apath; an archive or base64 travels inline as base64. This satisfies the ADRconsequence that a client-local path can't be handed to a remote end — it must be delivered and referenced.
Zipper.zip_rootpacks a file or directory as the archive's single top-level entry, which is what the Gridse/filenode unpack requires; the file-onlyzip_fileis kept as an alias to it for backwards compatibility.same error on a non-BiDi session.
🤖 AI assistance
💡 Additional Considerations
separate follow-up work.
API change.
🔄 Types of changes