|
|
Chromium Code Reviews|
Created:
3 years, 8 months ago by David Tseng Modified:
3 years, 8 months ago Reviewers:
dmazzoni CC:
chromium-reviews, extensions-reviews_chromium.org, alemate+watch_chromium.org, dtseng+watch_chromium.org, aboxhall+watch_chromium.org, nektar+watch_chromium.org, yuzo+watch_chromium.org, dougt+watch_chromium.org, arv+watch_chromium.org, oshima+watch_chromium.org, chromium-apps-reviews_chromium.org, je_julie, dmazzoni+watch_chromium.org Target Ref:
refs/heads/master Project:
chromium Visibility:
Public. |
DescriptionEnsure only one instance of AutomationInternalCustomBindings for background page extensions
Previously, if an extension requesting automation has more than one page it opens in its extension process (e.g. background.html and panel.html, in ChromeVox), we instantiated two AutomationInternalCustomBindings (one for each page).
This fix makes it so we only ever make "active" the instance that is associated with the extension's background page.
Note that as a result, any calls to chrome.automation from non-background page contexts will result in an no-op (e.g. getDesktop will not trigger the callback).
In the case that the extension has no background page, we revert to the previous behavior of having one instance per page.
TEST=open the ChromeVox Panel, and close it again. Press caps lock. Verify we only process one event and only output one alert.
BUG=691165
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation
Review-Url: https://codereview.chromium.org/2782753002
Cr-Commit-Position: refs/heads/master@{#460520}
Committed: https://chromium.googlesource.com/chromium/src/+/d64d9854a1d22208db2d97b7f441696ed0ca8fa0
Patch Set 1 #Patch Set 2 : Fix tests. #Patch Set 3 : Fix ChromeVox tests. #Patch Set 4 : Rebase. #
Messages
Total messages: 34 (25 generated)
Description was changed from ========== Ensure there is only ever one AutomationInternalCustomBindings active per automation extension Previously, if an extension requesting automation has more than one page it opens in its extension process (e.g. background.html and panel.html, in ChromeVox), we instantiated two AutomationInternalCustomBindings (one for each page). This fix makes it so we only ever make "active" the instance that is associated with the extension's background page. Note that as a result, any calls to chrome.automation from the context of non-background page contexts will result in an no-op as well as events delivered to the extension process. TEST=open the ChromeVox Panel, and close it again. Press caps lock. Verify we only process one event and only output one alert. BUG= ========== to ========== Ensure there is only ever one AutomationInternalCustomBindings active per automation extension Previously, if an extension requesting automation has more than one page it opens in its extension process (e.g. background.html and panel.html, in ChromeVox), we instantiated two AutomationInternalCustomBindings (one for each page). This fix makes it so we only ever make "active" the instance that is associated with the extension's background page. Note that as a result, any calls to chrome.automation from the context of non-background page contexts will result in an no-op as well as events delivered to the extension process. TEST=open the ChromeVox Panel, and close it again. Press caps lock. Verify we only process one event and only output one alert. BUG= CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation ==========
dtseng@chromium.org changed reviewers: + dmazzoni@chromium.org
The CQ bit was checked by dtseng@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: mac_chromium_rel_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_...)
The CQ bit was checked by dtseng@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_android_rel_ng on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/linux_androi...)
Description was changed from ========== Ensure there is only ever one AutomationInternalCustomBindings active per automation extension Previously, if an extension requesting automation has more than one page it opens in its extension process (e.g. background.html and panel.html, in ChromeVox), we instantiated two AutomationInternalCustomBindings (one for each page). This fix makes it so we only ever make "active" the instance that is associated with the extension's background page. Note that as a result, any calls to chrome.automation from the context of non-background page contexts will result in an no-op as well as events delivered to the extension process. TEST=open the ChromeVox Panel, and close it again. Press caps lock. Verify we only process one event and only output one alert. BUG= CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation ========== to ========== Ensure only one instance of AutomationInternalCustomBindings for background page extensions Previously, if an extension requesting automation has more than one page it opens in its extension process (e.g. background.html and panel.html, in ChromeVox), we instantiated two AutomationInternalCustomBindings (one for each page). This fix makes it so we only ever make "active" the instance that is associated with the extension's background page. Note that as a result, any calls to chrome.automation from the context of non-background page contexts will result in an no-op (e.g. getDesktop will not trigger the callback). In the case that the extension has no background page, we revert to the previous behavior of having one instance per page. TEST=open the ChromeVox Panel, and close it again. Press caps lock. Verify we only process one event and only output one alert. BUG=691165 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation ==========
Description was changed from ========== Ensure only one instance of AutomationInternalCustomBindings for background page extensions Previously, if an extension requesting automation has more than one page it opens in its extension process (e.g. background.html and panel.html, in ChromeVox), we instantiated two AutomationInternalCustomBindings (one for each page). This fix makes it so we only ever make "active" the instance that is associated with the extension's background page. Note that as a result, any calls to chrome.automation from the context of non-background page contexts will result in an no-op (e.g. getDesktop will not trigger the callback). In the case that the extension has no background page, we revert to the previous behavior of having one instance per page. TEST=open the ChromeVox Panel, and close it again. Press caps lock. Verify we only process one event and only output one alert. BUG=691165 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation ========== to ========== Ensure only one instance of AutomationInternalCustomBindings for background page extensions Previously, if an extension requesting automation has more than one page it opens in its extension process (e.g. background.html and panel.html, in ChromeVox), we instantiated two AutomationInternalCustomBindings (one for each page). This fix makes it so we only ever make "active" the instance that is associated with the extension's background page. Note that as a result, any calls to chrome.automation from non-background page contexts will result in an no-op (e.g. getDesktop will not trigger the callback). In the case that the extension has no background page, we revert to the previous behavior of having one instance per page. TEST=open the ChromeVox Panel, and close it again. Press caps lock. Verify we only process one event and only output one alert. BUG=691165 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation ==========
The CQ bit was checked by dtseng@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_chromium_chromeos_ozone_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
lgtm lgtm, but could you also file a bug for the underlying issue that the bindings are being instantiated on non-extension pages and assign to Devlin?
The CQ bit was checked by dtseng@chromium.org
The patchset sent to the CQ was uploaded after l-g-t-m from dmazzoni@chromium.org Link to the patchset: https://codereview.chromium.org/2782753002/#ps40001 (title: "Fix ChromeVox tests.")
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Try jobs failed on following builders: ios-device on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios-device/builds...)
dmazzoni@chromium.org writes: > lgtm > > lgtm, but could you also file a bug for the > underlying issue that the bindings are being instantiated > on non-extension pages and assign to Devlin? > Yes, that's an issue though not the root issue of this bug. Basically, I think there's nothing wrong with having an instance of the bindings per context since that's the way the DOM works (each context has a unique instance of window). It just doesn't make sense for automation since the bindings each get their own state which I don't think these native bindings were meant to do. We should think about perhaps sharing global state across all automation bindings and or having a non-extension based ipc to shuttle data to an AXTree in the extension process. -- You received this message because you are subscribed to the Google Groups "Chromium-reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to chromium-reviews+unsubscribe@chromium.org.
The CQ bit was checked by dtseng@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presub...) ios-simulator-xcode-clang on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios-simulator-xco...) mac_chromium_rel_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_...)
The CQ bit was checked by dtseng@chromium.org
The patchset sent to the CQ was uploaded after l-g-t-m from dmazzoni@chromium.org Link to the patchset: https://codereview.chromium.org/2782753002/#ps60001 (title: "Rebase.")
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
CQ is committing da patch.
Bot data: {"patchset_id": 60001, "attempt_start_ts": 1490812067621440,
"parent_rev": "78c7038fe6f981a9045d7d32d9f531ebb098fd80", "commit_rev":
"d64d9854a1d22208db2d97b7f441696ed0ca8fa0"}
Message was sent while issue was closed.
Description was changed from ========== Ensure only one instance of AutomationInternalCustomBindings for background page extensions Previously, if an extension requesting automation has more than one page it opens in its extension process (e.g. background.html and panel.html, in ChromeVox), we instantiated two AutomationInternalCustomBindings (one for each page). This fix makes it so we only ever make "active" the instance that is associated with the extension's background page. Note that as a result, any calls to chrome.automation from non-background page contexts will result in an no-op (e.g. getDesktop will not trigger the callback). In the case that the extension has no background page, we revert to the previous behavior of having one instance per page. TEST=open the ChromeVox Panel, and close it again. Press caps lock. Verify we only process one event and only output one alert. BUG=691165 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation ========== to ========== Ensure only one instance of AutomationInternalCustomBindings for background page extensions Previously, if an extension requesting automation has more than one page it opens in its extension process (e.g. background.html and panel.html, in ChromeVox), we instantiated two AutomationInternalCustomBindings (one for each page). This fix makes it so we only ever make "active" the instance that is associated with the extension's background page. Note that as a result, any calls to chrome.automation from non-background page contexts will result in an no-op (e.g. getDesktop will not trigger the callback). In the case that the extension has no background page, we revert to the previous behavior of having one instance per page. TEST=open the ChromeVox Panel, and close it again. Press caps lock. Verify we only process one event and only output one alert. BUG=691165 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation Review-Url: https://codereview.chromium.org/2782753002 Cr-Commit-Position: refs/heads/master@{#460520} Committed: https://chromium.googlesource.com/chromium/src/+/d64d9854a1d22208db2d97b7f441... ==========
Message was sent while issue was closed.
Committed patchset #4 (id:60001) as https://chromium.googlesource.com/chromium/src/+/d64d9854a1d22208db2d97b7f441... |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
