Closed Bug 1741861 Opened 1 year ago Closed 8 months ago

Move the _subscribeEvent logic fully to the root/session.jsm module

Categories

(Remote Protocol :: WebDriver BiDi, task, P1)

task
Points:
2

Tracking

(firefox103 fixed)

RESOLVED FIXED
103 Branch
Tracking Status
firefox103 --- fixed

People

(Reporter: jdescottes, Assigned: Sasha)

References

(Blocks 1 open bug)

Details

(Whiteboard: [webdriver:m4])

Attachments

(1 file)

At the moment we implement a _subscribeEvent command in the ROOT log.jsm module in order to check if the event names passed to session.subscribe are supported.

Instead, if the log module exposes the list of events it supports, this logic could be fully moved to the session.subscribe command, which will avoid code duplication when we start supporting events on other modules.

As discussed in https://phabricator.services.mozilla.com/D128284#inline-723314 we can also add shared methods to handle events in the abstract Module.jsm class.

Should work on this when implement another module with events, eg Bug 1694389

Blocks: 1713438
See Also: → 1694389
Whiteboard: [webdriver:triage]
Priority: -- → P3
Whiteboard: [bidi-m3-mvp]

Before working on this bug it would be good to have a second event implemented in a module.

Priority: P3 → P1
Whiteboard: [bidi-m3-mvp] → [webdriver:m4]
Assignee: nobody → aborovova
Status: NEW → ASSIGNED
Attachment #9281432 - Attachment description: WIP: Bug 1741861 - Move the _subscribeEvent and _unsubscribeEvent to abstract Module class → WIP: Bug 1741861 - Move shared logic to RootModule and WindowGlobalModule
Attachment #9281432 - Attachment description: WIP: Bug 1741861 - Move shared logic to RootModule and WindowGlobalModule → Bug 1741861 - Move shared logic to RootModule and WindowGlobalModule. r=jdescottes
Attachment #9281432 - Attachment description: Bug 1741861 - Move shared logic to RootModule and WindowGlobalModule. r=jdescottes → Bug 1741861 - Move shared logic from _subscribeEvent and _unsubscribeEvent. r=jdescottes
Pushed by aborovova@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/1acf89b996d9
Move shared logic from _subscribeEvent and _unsubscribeEvent. r=webdriver-reviewers,jdescottes
Status: ASSIGNED → RESOLVED
Closed: 8 months ago
Resolution: --- → FIXED
Target Milestone: --- → 103 Branch
You need to log in before you can comment on or make changes to this bug.