Remove osfile.jsm usage from toolkit/components/extensions/
Categories
(Toolkit Graveyard :: OS.File, task, P3)
Tracking
(firefox114 fixed)
Tracking | Status | |
---|---|---|
firefox114 | --- | fixed |
People
(Reporter: barret, Assigned: barret)
References
Details
Attachments
(1 file)
Assignee | ||
Updated•1 year ago
|
Assignee | ||
Comment 1•1 year ago
|
||
Depends on D159954
Pushed by brennie@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/fe873903aade Port osfile.jsm usage to IOUtils in toolkit/components/extensions r=mixedpuppy
Comment 3•11 months ago
|
||
Backed out for causing downloads related mochitests failures.
- Backout link
- Push with failures
- Failure Log
- Failure line: TEST-UNEXPECTED-FAIL | toolkit/components/extensions/test/mochitest/test_chrome_ext_downloads_open.html | The error is informative. - got "An unexpected error occurred", expected "Invalid download id 10"
Assignee | ||
Updated•11 months ago
|
Pushed by brennie@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/1df084d8816a Port osfile.jsm usage to IOUtils in toolkit/components/extensions r=mixedpuppy
Backout by sstanca@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/5bb8ff406a31 Backed out changeset 1df084d8816a for causing xpcshell failures on test_ext_storage_idb_data_migration.js. CLOSED TREE
Comment 6•11 months ago
|
||
Backed out for causing xpcshell failures on test_ext_storage_idb_data_migration.js.
- Backout link
- Push with failures
- Failure Log
- Failure line: TEST-UNEXPECTED-FAIL | xpcshell-remote.ini:toolkit/components/extensions/test/xpcshell/test_ext_storage_idb_data_migration.js | xpcshell return code: -11
Assignee | ||
Updated•10 months ago
|
Comment 7•9 months ago
|
||
There's a r+ patch which didn't land and no activity in this bug for 2 weeks.
:barret, could you have a look please?
If you still have some work to do, you can add an action "Plan Changes" in Phabricator.
For more information, please visit auto_nag documentation.
Comment 8•7 months ago
|
||
Barret, are you interest in pursuing this patch further? If not, I can take it over.
bug 1807815 has made a change in ext-downloads that need to be accounted for in the (rebased) update.
I see code like this: https://searchfox.org/mozilla-central/rev/75da1dd5d4b9b991f919a41594194eab93cdef62/toolkit/components/extensions/parent/ext-geckoProfiler.js#10-12
That should be removed, in favor of exposing IOUtils and PathUtils via https://searchfox.org/mozilla-central/rev/75da1dd5d4b9b991f919a41594194eab93cdef62/toolkit/components/extensions/ExtensionCommon.jsm#1835-1854
Assignee | ||
Comment 9•7 months ago
|
||
Sorry it took so long to get back to this, but I'm actively working on this.
Comment 10•7 months ago
|
||
Pushed by brennie@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/4e2a9894fb4c Port osfile.jsm usage to IOUtils in toolkit/components/extensions r=mixedpuppy
Comment 11•7 months ago
|
||
Backed out for causing bc failures on browser_addon_list_reordering.js.
[task 2023-02-25T05:57:04.186Z] 05:57:04 INFO - TEST-PASS | toolkit/mozapps/extensions/test/browser/browser_addon_list_reordering.js | Should be closing window with correct URI -
[task 2023-02-25T05:57:04.187Z] 05:57:04 INFO - Telling manager window to close
[task 2023-02-25T05:57:04.187Z] 05:57:04 INFO - Manager window close() call returned
[task 2023-02-25T05:57:04.187Z] 05:57:04 INFO - Buffered messages logged at 05:57:04
[task 2023-02-25T05:57:04.187Z] 05:57:04 INFO - Console message: 1677304623988 addons.xpi DEBUG Loading bootstrap scope from jar:file:///C:/Users/task_167730225971765/AppData/Local/Temp/generated-extension.xpi!/
[task 2023-02-25T05:57:04.188Z] 05:57:04 INFO - Console message: 1677304623988 addons.xpi DEBUG Calling bootstrap method uninstall on one@mochi.test version 1.0
[task 2023-02-25T05:57:04.189Z] 05:57:04 INFO - Console message: 1677304623991 addons.xpi DEBUG Disabling XPIState for one@mochi.test
[task 2023-02-25T05:57:04.190Z] 05:57:04 INFO - Console message: [JavaScript Error: "TypeError: can't access property "ownerGlobal", browser is null" {file: "resource://gre/actors/BrowserElementParent.jsm" line: 24}]
[task 2023-02-25T05:57:04.190Z] 05:57:04 INFO - receiveMessage@resource://gre/actors/BrowserElementParent.jsm:24:21
[task 2023-02-25T05:57:04.190Z] 05:57:04 INFO -
[task 2023-02-25T05:57:04.190Z] 05:57:04 INFO - Console message: 1677304624009 addons.xpi DEBUG Loading bootstrap scope from jar:file:///C:/Users/task_167730225971765/AppData/Local/Temp/generated-extension.xpi!/
[task 2023-02-25T05:57:04.191Z] 05:57:04 INFO - Console message: 1677304624009 addons.xpi DEBUG Calling bootstrap method uninstall on one@mochi.test version 1.0
[task 2023-02-25T05:57:04.191Z] 05:57:04 INFO - Console message: 1677304624010 addons.xpi DEBUG Disabling XPIState for one@mochi.test
[task 2023-02-25T05:57:04.192Z] 05:57:04 INFO - Console message: 1677304624013 addons.xpi DEBUG Calling bootstrap method shutdown on two@mochi.test version 1.0
[task 2023-02-25T05:57:04.192Z] 05:57:04 INFO - Console message: 1677304624016 addons.xpi DEBUG Loading bootstrap scope from jar:file:///C:/Users/task_167730225971765/AppData/Local/Temp/generated-extension-2.xpi!/
[task 2023-02-25T05:57:04.193Z] 05:57:04 INFO - Console message: 1677304624017 addons.xpi DEBUG Calling bootstrap method uninstall on three@mochi.test version 1.0
[task 2023-02-25T05:57:04.193Z] 05:57:04 INFO - Console message: 1677304624017 addons.xpi DEBUG Disabling XPIState for three@mochi.test
[task 2023-02-25T05:57:04.193Z] 05:57:04 INFO - Console message: 1677304624021 addons.xpi DEBUG Calling bootstrap method shutdown on four@mochi.test version 1.0
[task 2023-02-25T05:57:04.194Z] 05:57:04 INFO - Console message: 1677304624024 addons.xpi DEBUG Calling bootstrap method shutdown on five@mochi.test version 1.0
[task 2023-02-25T05:57:04.194Z] 05:57:04 INFO - Console message: 1677304624035 addons.xpi DEBUG Calling bootstrap method uninstall on two@mochi.test version 1.0
[task 2023-02-25T05:57:04.195Z] 05:57:04 INFO - Console message: 1677304624036 addons.xpi DEBUG Disabling XPIState for two@mochi.test
[task 2023-02-25T05:57:04.195Z] 05:57:04 INFO - Console message: 1677304624041 addons.xpi DEBUG Calling bootstrap method uninstall on four@mochi.test version 1.0
[task 2023-02-25T05:57:04.196Z] 05:57:04 INFO - Console message: 1677304624042 addons.xpi DEBUG Disabling XPIState for four@mochi.test
[task 2023-02-25T05:57:04.196Z] 05:57:04 INFO - Console message: 1677304624045 addons.xpi DEBUG Calling bootstrap method uninstall on five@mochi.test version 1.0
[task 2023-02-25T05:57:04.197Z] 05:57:04 INFO - Console message: 1677304624046 addons.xpi DEBUG Disabling XPIState for five@mochi.test
[task 2023-02-25T05:57:04.197Z] 05:57:04 INFO - Buffered messages finished
[task 2023-02-25T05:57:04.197Z] 05:57:04 INFO - TEST-UNEXPECTED-FAIL | toolkit/mozapps/extensions/test/browser/browser_addon_list_reordering.js | Uncaught exception in test bound testReordering - {}
[task 2023-02-25T05:57:04.198Z] 05:57:04 INFO - Leaving test bound testReordering
[task 2023-02-25T05:57:04.412Z] 05:57:04 INFO - GECKO(7472) | MEMORY STAT | vsize 2112397MB | vsizeMaxContiguous 65081711MB | residentFast 306MB | heapAllocated 153MB
[task 2023-02-25T05:57:04.415Z] 05:57:04 INFO - TEST-OK | toolkit/mozapps/extensions/test/browser/browser_addon_list_reordering.js | took 1693ms
[task 2023-02-25T05:57:04.426Z] 05:57:04 INFO - checking window state
[task 2023-02-25T05:57:04.437Z] 05:57:04 INFO - TEST-START | toolkit/mozapps/extensions/test/browser/browser_bug572561.js
Assignee | ||
Comment 12•7 months ago
|
||
I've investigated this and found two things:
- OS.File.Remove on Windows will retry deletions if the result is a ACCESS_DENIED by removing the readonly flag on the file.
- Fixing #1 results in TelemetryStorage.sys.mjs being the first module to import OS.File, which is triggered at shutdown. Then we get an error attempting to add a blocker:
0:26.71 GECKO(17668) WARNING: A blocker encountered an error while we were waiting.
0:26.71 GECKO(17668) Blocker: Waiting for ping task
0:26.71 GECKO(17668) Phase: TelemetryController: Waiting for pending ping activity
0:26.71 GECKO(17668) State: (none)
0:26.71 GECKO(17668) WARNING: Error: Phase "profile-before-change" is finished, it is too late to register completion condition "OS.File: flush I/O queued before profileBeforeChange"
0:26.71 GECKO(17668) WARNING: addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:727:15
0:26.71 GECKO(17668) addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:523:26
0:26.71 GECKO(17668) addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:458:15
0:26.71 GECKO(17668) setupShutdown@resource://gre/modules/osfile/osfile_async_front.jsm:1548:28
0:26.71 GECKO(17668) @resource://gre/modules/osfile/osfile_async_front.jsm:1568:16
0:26.71 GECKO(17668) @resource://gre/modules/osfile.jsm:12:30
0:26.71 GECKO(17668) @resource://gre/modules/TelemetryStorage.sys.mjs:10:28
0:26.72 GECKO(17668) _checkPendingPings@resource://gre/modules/TelemetrySend.sys.mjs:863:17
0:26.72 GECKO(17668) setup@resource://gre/modules/TelemetrySend.sys.mjs:803:18
0:26.72 GECKO(17668) setup@resource://gre/modules/TelemetrySend.sys.mjs:241:30
0:26.72 GECKO(17668) setupTelemetry/this._delayedInitTask<@resource://gre/modules/TelemetryControllerParent.sys.mjs:828:36
Comment 13•5 months ago
|
||
Pushed by brennie@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/5db899d2ce61 Port osfile.jsm usage to IOUtils in toolkit/components/extensions r=mixedpuppy
Comment 14•5 months ago
|
||
Backed out for causing failures related to osfile
- backout: https://hg.mozilla.org/integration/autoland/rev/0d9a5c60e77cbe00a01c5e3d7aa9b39f36ca97d0
- push: https://treeherder.mozilla.org/jobs?repo=autoland&group_state=expanded&revision=5db899d2ce61779d80680f1ee883a923fbc46c61
- failure log: https://treeherder.mozilla.org/logviewer?job_id=413835868&repo=autoland&lineNumber=3475
[task 2023-04-26T11:14:16.131Z] 11:14:16 INFO - Buffered messages finished
[task 2023-04-26T11:14:16.132Z] 11:14:16 INFO - TEST-UNEXPECTED-FAIL | browser/base/content/test/static/browser_all_files_referenced.js | there should be no unreferenced files - Got 13, expected +0
[task 2023-04-26T11:14:16.132Z] 11:14:16 INFO - Stack trace:
[task 2023-04-26T11:14:16.132Z] 11:14:16 INFO - chrome://mochikit/content/browser-test.js:test_is:1606
[task 2023-04-26T11:14:16.132Z] 11:14:16 INFO - chrome://mochitests/content/browser/browser/base/content/test/static/browser_all_files_referenced.js:checkAllTheFiles:1047
[task 2023-04-26T11:14:16.132Z] 11:14:16 INFO - chrome://mochikit/content/browser-test.js:handleTask:1127
[task 2023-04-26T11:14:16.132Z] 11:14:16 INFO - chrome://mochikit/content/browser-test.js:_runTaskBasedTest:1199
[task 2023-04-26T11:14:16.132Z] 11:14:16 INFO - chrome://mochikit/content/browser-test.js:Tester_execTest:1341
[task 2023-04-26T11:14:16.132Z] 11:14:16 INFO - chrome://mochikit/content/browser-test.js:nextTest/<:1116
[task 2023-04-26T11:14:16.132Z] 11:14:16 INFO - chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:SimpleTest.waitForFocus/<:1056
[task 2023-04-26T11:14:16.133Z] 11:14:16 INFO - Not taking screenshot here: see the one that was previously logged
[task 2023-04-26T11:14:16.135Z] 11:14:16 INFO - TEST-UNEXPECTED-FAIL | browser/base/content/test/static/browser_all_files_referenced.js | file only referenced from unreferenced files: resource://gre/modules/lz4.js referenced from resource://gre/modules/osfile/osfile_shared_front.js -
[task 2023-04-26T11:14:16.135Z] 11:14:16 INFO - Stack trace:
[task 2023-04-26T11:14:16.135Z] 11:14:16 INFO - chrome://mochikit/content/browser-test.js:test_ok:1578
[task 2023-04-26T11:14:16.135Z] 11:14:16 INFO - chrome://mochitests/content/browser/browser/base/content/test/static/browser_all_files_referenced.js:checkAllTheFiles:1058
[task 2023-04-26T11:14:16.135Z] 11:14:16 INFO - chrome://mochikit/content/browser-test.js:handleTask:1127
[task 2023-04-26T11:14:16.135Z] 11:14:16 INFO - chrome://mochikit/content/browser-test.js:_runTaskBasedTest:1199
[task 2023-04-26T11:14:16.135Z] 11:14:16 INFO - chrome://mochikit/content/browser-test.js:Tester_execTest:1341
[task 2023-04-26T11:14:16.135Z] 11:14:16 INFO - chrome://mochikit/content/browser-test.js:nextTest/<:1116
[task 2023-04-26T11:14:16.135Z] 11:14:16 INFO - chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:SimpleTest.waitForFocus/<:1056
[task 2023-04-26T11:14:16.136Z] 11:14:16 INFO - Not taking screenshot here: see the one that was previously logged
Assignee | ||
Updated•5 months ago
|
Comment 15•5 months ago
|
||
Pushed by brennie@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/cff507e2b180 Port osfile.jsm usage to IOUtils in toolkit/components/extensions r=mixedpuppy
Comment 16•5 months ago
|
||
bugherder |
Updated•5 months ago
|
Description
•