Use the ResourceWatcher API to fetch Stylesheets
Categories
(DevTools :: Style Editor, task, P2)
Tracking
(Fission Milestone:M6c, firefox80 fixed)
Tracking | Status | |
---|---|---|
firefox80 | --- | fixed |
People
(Reporter: ochameau, Assigned: daisuke)
References
(Blocks 1 open bug, Regressed 1 open bug)
Details
(Whiteboard: dt-fission-m2-mvp)
Attachments
(7 files)
47 bytes,
text/x-phabricator-request
|
Details | Review | |
47 bytes,
text/x-phabricator-request
|
Details | Review | |
47 bytes,
text/x-phabricator-request
|
Details | Review | |
47 bytes,
text/x-phabricator-request
|
Details | Review | |
47 bytes,
text/x-phabricator-request
|
Details | Review | |
47 bytes,
text/x-phabricator-request
|
Details | Review | |
47 bytes,
text/x-phabricator-request
|
Details | Review |
Bug 1576624 introduced the ResourceWatcher
API, accessible via toolbox.resourceWatcher
. This API will help listen to data that is being created early, when the document just started loading.
We should migrate the whole DevTools codebase to this API for any data that:
- DevTools frontend listen to, or care about,
and, - may be created or be notified early, when the document just starts being loaded.
This data will typically be: console messages, errors, warnings, sources, Root element NodeFront, storage values, network events, stylesheets, ...
We are typically not going to use this API for:
- data being fetched on-demand, from user's input. For ex: webconsole evaluation input, or, DOM element expands from the Markup view.
- events which we only want to record when the user cares about them. For ex: animation events.
For some more high level context, please have a look at Migration to Fission-compatible APIs, which describes all Fission-related refactorings.
The typical task for this bug will be about migrating code that:
- start listening and register a RDP event listener,
- retrieve already existings data,
from panel's codebase, to theResourceWatcher
module, in theLegacyListener
object.
And then, the panel should use theResourceWatcher
instead.
Bug 1620234 is a good example of such migration, applied to Console Messages.
Bug 1623699 is also useful example as it demonstrates how to write tests for such migration.
This bug is about focusing on only one usecase: the StyleSheets.
StyleSheets are currently being listened via stylesheet-added
, from here:
https://searchfox.org/mozilla-central/search?q=stylesheet-added&case=false®exp=false&path=devtools%2Fclient
And already existing ones retrieved from here:
https://searchfox.org/mozilla-central/search?q=.getStyleSheets&case=false®exp=false&path=devtools%2Fclient
We may split this bug in two:
- addressing the style editor panel
- migrating the source map service
Reporter | ||
Updated•5 years ago
|
Comment 1•5 years ago
|
||
Tracking Fission DevTools bugs for Fission Nightly (M6) milestone
Comment 2•5 years ago
|
||
Tracking dt-fission-m2-mvp bugs for Fission Nightly milestone (M6c)
Assignee | ||
Updated•4 years ago
|
Assignee | ||
Comment 3•4 years ago
|
||
Assignee | ||
Comment 4•4 years ago
|
||
Depends on D78239
Assignee | ||
Comment 5•4 years ago
|
||
Depends on D78240
Assignee | ||
Comment 6•4 years ago
|
||
Depends on D78241
Assignee | ||
Comment 7•4 years ago
|
||
Assignee | ||
Comment 8•4 years ago
|
||
Depends on D78242
Comment 10•4 years ago
|
||
Backed out 6 changesets (bug 1625930) for test_eventemitter_basic.js failures
Backout link: https://hg.mozilla.org/integration/autoland/rev/2ac643a3f849374fa4fd63ae091e27b8220a18d6
Failure log: https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=308993023&repo=autoland&lineNumber=9769
[task 2020-07-08T15:04:58.063Z] 15:04:58 INFO - TEST-START | devtools/shared/tests/xpcshell/test_eventemitter_basic.js
[task 2020-07-08T15:04:58.410Z] 15:04:58 WARNING - TEST-UNEXPECTED-FAIL | devtools/shared/tests/xpcshell/test_eventemitter_basic.js | xpcshell return code: 0
[task 2020-07-08T15:04:58.411Z] 15:04:58 INFO - TEST-INFO took 351ms
[task 2020-07-08T15:04:58.411Z] 15:04:58 INFO - >>>>>>>
[task 2020-07-08T15:04:58.412Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: Failed to get directory to cache.: file /builds/worker/checkouts/gecko/security/sandbox/win/src/sandboxbroker/sandboxBroker.cpp, line 121
[task 2020-07-08T15:04:58.412Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: Failed to get directory to cache.: file /builds/worker/checkouts/gecko/security/sandbox/win/src/sandboxbroker/sandboxBroker.cpp, line 121
[task 2020-07-08T15:04:58.412Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: Failed to get directory to cache.: file /builds/worker/checkouts/gecko/security/sandbox/win/src/sandboxbroker/sandboxBroker.cpp, line 121
[task 2020-07-08T15:04:58.413Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: Failed to get directory to cache.: file /builds/worker/checkouts/gecko/security/sandbox/win/src/sandboxbroker/sandboxBroker.cpp, line 121
[task 2020-07-08T15:04:58.413Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: Failed to get directory to cache.: file /builds/worker/checkouts/gecko/security/sandbox/win/src/sandboxbroker/sandboxBroker.cpp, line 121
[task 2020-07-08T15:04:58.413Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: Couldn't get the user appdata directory. Crash events may not be produced.: file /builds/worker/checkouts/gecko/toolkit/crashreporter/nsExceptionHandler.cpp, line 2914
[task 2020-07-08T15:04:58.414Z] 15:04:58 INFO - (xpcshell/head.js) | test MAIN run_test pending (1)
[task 2020-07-08T15:04:58.414Z] 15:04:58 INFO - (xpcshell/head.js) | test run_next_test 0 pending (2)
[task 2020-07-08T15:04:58.414Z] 15:04:58 INFO - (xpcshell/head.js) | test MAIN run_test finished (2)
[task 2020-07-08T15:04:58.414Z] 15:04:58 INFO - running event loop
[task 2020-07-08T15:04:58.414Z] 15:04:58 INFO - devtools/shared/tests/xpcshell/test_eventemitter_basic.js | Starting
[task 2020-07-08T15:04:58.414Z] 15:04:58 INFO - (xpcshell/head.js) | test pending (2)
[task 2020-07-08T15:04:58.414Z] 15:04:58 INFO - "testEventEmitterCreation"
[task 2020-07-08T15:04:58.414Z] 15:04:58 INFO - TEST-PASS | devtools/shared/tests/xpcshell/test_eventemitter_basic.js | - We have an event emitter - {} == true
[task 2020-07-08T15:04:58.414Z] 15:04:58 WARNING - TEST-UNEXPECTED-FAIL | devtools/shared/tests/xpcshell/test_eventemitter_basic.js | - Event Emitter instance has the expected methods. - false == true
[task 2020-07-08T15:04:58.414Z] 15:04:58 INFO - Z:/task_1594219050/build/tests/xpcshell/tests/devtools/shared/tests/xpcshell/test_eventemitter_basic.js:testEventEmitterCreation:27
[task 2020-07-08T15:04:58.414Z] 15:04:58 INFO - Z:/task_1594219050/build/tests/xpcshell/tests/devtools/shared/tests/xpcshell/test_eventemitter_basic.js:runnable/<:355
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - Z:\task_1594219050\build\tests\xpcshell\head.js:_run_next_test/<:1618
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - Z:\task_1594219050\build\tests\xpcshell\head.js:_run_next_test:1618
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - Z:\task_1594219050\build\tests\xpcshell\head.js:run:777
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - Z:\task_1594219050\build\tests\xpcshell\head.js:_do_main:248
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - Z:\task_1594219050\build\tests\xpcshell\head.js:_execute_test:577
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - -e:null:1
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - exiting test
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - (xpcshell/head.js) | test run_next_test 0 finished (2)
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - Unexpected exception NS_ERROR_ABORT:
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - _abort_failed_test@Z:\task_1594219050\build\tests\xpcshell\head.js:833:20
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - do_report_result@Z:\task_1594219050\build\tests\xpcshell\head.js:934:5
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - Assert<@Z:\task_1594219050\build\tests\xpcshell\head.js:73:21
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - proto.report@resource://testing-common/Assert.jsm:233:10
[task 2020-07-08T15:04:58.415Z] 15:04:58 INFO - proto.ok@resource://testing-common/Assert.jsm:259:10
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - testEventEmitterCreation@Z:/task_1594219050/build/tests/xpcshell/tests/devtools/shared/tests/xpcshell/test_eventemitter_basic.js:27:7
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - runnable/<@Z:/task_1594219050/build/tests/xpcshell/tests/devtools/shared/tests/xpcshell/test_eventemitter_basic.js:355:26
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - _run_next_test/<@Z:\task_1594219050\build\tests\xpcshell\head.js:1618:22
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - _run_next_test@Z:\task_1594219050\build\tests\xpcshell\head.js:1618:38
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - run@Z:\task_1594219050\build\tests\xpcshell\head.js:777:9
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - _do_main@Z:\task_1594219050\build\tests\xpcshell\head.js:248:6
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - _execute_test@Z:\task_1594219050\build\tests\xpcshell\head.js:577:5
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - @-e:1:1
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - exiting test
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: Extra shutdown CC: 'i < NORMAL_SHUTDOWN_COLLECTIONS', file /builds/worker/checkouts/gecko/xpcom/base/nsCycleCollector.cpp, line 3359
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: OOPDeinit() without successful OOPInit(): file /builds/worker/checkouts/gecko/toolkit/crashreporter/nsExceptionHandler.cpp, line 3359
[task 2020-07-08T15:04:58.416Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: NS_ENSURE_TRUE(Preferences::InitStaticMembers()) failed: file /builds/worker/checkouts/gecko/modules/libpref/Preferences.cpp, line 4382
[task 2020-07-08T15:04:58.417Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: XPCOM objects created/destroyed from static ctor/dtor: file /builds/worker/checkouts/gecko/xpcom/base/nsTraceRefcnt.cpp, line 202
[task 2020-07-08T15:04:58.417Z] 15:04:58 INFO - PID 11936 | [11936, Main Thread] WARNING: XPCOM objects created/destroyed from static ctor/dtor: file /builds/worker/checkouts/gecko/xpcom/base/nsTraceRefcnt.cpp, line 202
[task 2020-07-08T15:04:58.417Z] 15:04:58 INFO - <<<<<<<
Assignee | ||
Comment 11•4 years ago
|
||
Assignee | ||
Updated•4 years ago
|
Comment 12•4 years ago
|
||
Comment 13•4 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/6697f0e16d37
https://hg.mozilla.org/mozilla-central/rev/1804cf02e1b8
https://hg.mozilla.org/mozilla-central/rev/a481df06a3d6
https://hg.mozilla.org/mozilla-central/rev/79a78fec37d1
https://hg.mozilla.org/mozilla-central/rev/b1d803cbd8a6
https://hg.mozilla.org/mozilla-central/rev/fcddaa09a355
https://hg.mozilla.org/mozilla-central/rev/f9da5a877d11
Description
•