131 Commits
Author SHA1 Message Date
Sylvestre Ledru 074b376055 Bug 2023419 - Remove Emacs/Vim modelines from devtools/ r=emilio,devtools-backward-compat-reviewers,devtools-reviewers,nchevobbe
replaced by .editorconfig
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D287841
2026-03-28 10:21:10 +00:00
Alexandru Marc 630e6cf0e8 Revert "Bug 2023419 - Remove Emacs/Vim modelines from devtools/ r=emilio,devtools-backward-compat-reviewers,devtools-reviewers,nchevobbe" for causing devtools failures
This reverts commit ed535dace9.
2026-03-17 12:46:01 +00:00
Sylvestre Ledru ed535dace9 Bug 2023419 - Remove Emacs/Vim modelines from devtools/ r=emilio,devtools-backward-compat-reviewers,devtools-reviewers,nchevobbe
replaced by .editorconfig

Differential Revision: https://phabricator.services.mozilla.com/D287841
2026-03-17 12:03:34 +00:00
Rob Wu f44d1741ca Bug 2017957 - Add freezeBuiltins option to Cu.Sandbox r=jandem,devtools-reviewers,ochameau
Differential Revision: https://phabricator.services.mozilla.com/D284192
2026-02-28 05:41:54 +00:00
Serban Stanca 2f51af57a3 Revert "Bug 2017957 - Add freezeBuiltins option to Cu.Sandbox r=jandem,devtools-reviewers,ochameau" for causing wpt failures in PLDHashTable.h.
This reverts commit 2c77783d29.
2026-02-28 03:00:30 +00:00
Rob Wu 2c77783d29 Bug 2017957 - Add freezeBuiltins option to Cu.Sandbox r=jandem,devtools-reviewers,ochameau
Differential Revision: https://phabricator.services.mozilla.com/D284192
2026-02-27 20:38:47 +00:00
Cristina Horotan 315099c752 Revert "Bug 2017957 - Add freezeBuiltins option to Cu.Sandbox r=jandem,devtools-reviewers,ochameau" for causing dt failures on browser_jsonview_multipart_response.js
This reverts commit f5110b4c98.
2026-02-26 02:26:27 +00:00
Rob Wu f5110b4c98 Bug 2017957 - Add freezeBuiltins option to Cu.Sandbox r=jandem,devtools-reviewers,ochameau
Differential Revision: https://phabricator.services.mozilla.com/D284192
2026-02-26 00:49:10 +00:00
Nicolas Chevobbe 10fea5acc2 Bug 2005233 - Expose CSSPositionTryDescriptors in DevTools sandbox. r=devtools-reviewers,ochameau
This will be used to compute the list of supported CSS properties for @position-try rules.

Differential Revision: https://phabricator.services.mozilla.com/D275933
2025-12-16 08:04:17 +00:00
Lorenz A ad0ae2c01b Bug 2004233 - [devtools] Turn devtools/shared/loader/browser-loader.sys.mjs into an ES class. r=devtools-reviewers,bomsy
Differential Revision: https://phabricator.services.mozilla.com/D275636
2025-12-11 07:10:13 +00:00
Lorenz A 1e90610dee Bug 2004234 - [devtools] Turn devtools/shared/loader/Loader.sys.mjs into an ES class. r=devtools-reviewers,bomsy
Differential Revision: https://phabricator.services.mozilla.com/D275639
2025-12-11 07:06:07 +00:00
Mark Banner b38cd3110b Bug 1999554 - Automatically fix ESLint rule jsdoc/check-types for devtools/. r=devtools-reviewers,devtools-backward-compat-reviewers,profiler-reviewers,canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D272173
2025-11-21 16:16:08 +00:00
Mark Banner 2542790f53 Bug 1998787 - Automatic fixes for enabling ESLint jsdoc/tag-line rule everywhere. r=frontend-codestyle-reviewers,mtigley,perftest-reviewers,nchevobbe,home-newtab-reviewers,Gijs,mconley,sparky
Differential Revision: https://phabricator.services.mozilla.com/D271745
2025-11-10 21:27:12 +00:00
Mark Banner 32474de169 Bug 1993543 - Change XPCOMUtils.defineLazyServiceGetter(s) calls to pass an nsIID rather than a string. r=firefox-desktop-core-reviewers ,mtigley,joschmidt,perftest-reviewers,home-newtab-reviewers,nbarrett,Gijs,sparky
This is all automated changes apart from ShellService.sys.mjs.

Differential Revision: https://phabricator.services.mozilla.com/D268194
2025-10-17 22:13:14 +00:00
Atila Butkovits 091d1f53bd Revert "Bug 1993543 - Simplify XPCOMUtils.defineLazyServiceGetter to require the interface parameter as an nsIID. r=spidermonkey-reviewers,frontend-codestyle-reviewers,Gijs,arai" for causing Reftest failures.
This reverts commit d96e9bd92c.

Revert "Bug 1993543 - Change XPCOMUtils.defineLazyServiceGetter(s) calls to pass an nsIID rather than a string. r=firefox-desktop-core-reviewers ,mtigley,joschmidt,perftest-reviewers,home-newtab-reviewers,nbarrett,Gijs,sparky"

This reverts commit 024c584172.
2025-10-17 12:51:54 +00:00
Mark Banner dde0952bd6 Bug 1994217 - Enable ESLint rule jsdoc/no-bad-blocks on the rest of the tree. r=frontend-codestyle-reviewers,Gijs
This is mainly automatic changes, with some manual fixes to move text off of the first line.

Differential Revision: https://phabricator.services.mozilla.com/D268570
2025-10-17 11:18:46 +00:00
Mark Banner 024c584172 Bug 1993543 - Change XPCOMUtils.defineLazyServiceGetter(s) calls to pass an nsIID rather than a string. r=firefox-desktop-core-reviewers ,mtigley,joschmidt,perftest-reviewers,home-newtab-reviewers,nbarrett,Gijs,sparky
This is all automated changes apart from ShellService.sys.mjs.

Differential Revision: https://phabricator.services.mozilla.com/D268194
2025-10-17 11:16:12 +00:00
Narcis Beleuzu 89c0ffec7c Revert "Bug 1994217 - Enable ESLint rule jsdoc/no-bad-blocks on the rest of the tree. r=frontend-codestyle-reviewers,Gijs" for causing Documentation opt failure
This reverts commit 987c3ad130.

This reverts commit 1c5b20a293.

This reverts commit 0a9a458465.
2025-10-16 21:32:01 +00:00
Mark Banner 987c3ad130 Bug 1994217 - Enable ESLint rule jsdoc/no-bad-blocks on the rest of the tree. r=frontend-codestyle-reviewers,Gijs
This is mainly automatic changes, with some manual fixes to move text off of the first line.

Differential Revision: https://phabricator.services.mozilla.com/D268570
2025-10-16 10:58:14 +00:00
Alexandre Poirot 95222ec51e Bug 1970328 - [devtools] Remove DevToolsLoader's invisibleToDebugger flag. r=devtools-reviewers,jdescottes
This flag was only used by the allocation tracker test and we can now rely on the
DevTools global spawn by mozJSModuleLoader.

Differential Revision: https://phabricator.services.mozilla.com/D253049
2025-06-11 16:01:34 +00:00
Alexandre Poirot 382fe92da5 Bug 1970328 - [devtools] Load DevTools server modules in a distinct compartment when debuggign xpcshell tests. r=devtools-reviewers,jdescottes
The 'invisibleToDebugger' flag was misleading and making all Loaders be indebuggable on xcpshell.
But we have to keep spawning the xpcshell's DevToolsServer in the distinct "devtools" global
in order to be able to debug the tests and devtools globals now all spawn in the shared system global.

Differential Revision: https://phabricator.services.mozilla.com/D252530
2025-06-11 16:01:31 +00:00
Alexandre Poirot 833ef8762c Bug 1958081 - [devtools] Introduce a test framework to ease testing all possible JavaScript types against various codebases. r=frontend-codestyle-reviewers,devtools-reviewers,nchevobbe,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D244246
2025-05-13 12:34:02 +00:00
Serban Stanca 1dac11cfa9 Revert "Bug 1958081 - [devtools] Cover JS Tracer stringification with the new JS Objects test framework. r=devtools-reviewers,nchevobbe" for causing devtools failures in browser_webconsole_reverse_search.js.
This reverts commit a07e576742.

This reverts commit f0b5190845.

This reverts commit 1761d4c3dd.
2025-05-08 23:00:24 +00:00
Alexandre Poirot 1761d4c3dd Bug 1958081 - [devtools] Introduce a test framework to ease testing all possible JavaScript types against various codebases. r=frontend-codestyle-reviewers,devtools-reviewers,nchevobbe,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D244246
2025-05-08 20:04:57 +00:00
Cristina Horotan 539746f658 Revert "Bug 1958081 - [devtools] Cover JS Tracer stringification with the new JS Objects test framework. r=devtools-reviewers,nchevobbe" for xpcshell failures at test_javascript_logging.js
This reverts commit 6056567c3e.

Revert "Bug 1958081 - [devtools] Migrate object inspector to the new JS objects test framework. r=devtools-reviewers,nchevobbe"

This reverts commit 8cbc65e7b5.

Revert "Bug 1958081 - [devtools] Introduce a test framework to ease testing all possible JavaScript types against various codebases. r=frontend-codestyle-reviewers,devtools-reviewers,nchevobbe,Standard8" for causing xpc failures at test_javascript_logging.js

This reverts commit ddcbf73cd8.
2025-05-08 05:42:19 +00:00
Alexandre Poirot ddcbf73cd8 Bug 1958081 - [devtools] Introduce a test framework to ease testing all possible JavaScript types against various codebases. r=frontend-codestyle-reviewers,devtools-reviewers,nchevobbe,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D244246
2025-05-08 04:05:01 +00:00
Florian Quèze a1da324152 Bug 1950710 - remove the TelemetryStopwatch API, r=chutten,devtools-reviewers,home-newtab-reviewers,frontend-codestyle-reviewers,mconley,nchevobbe.
Differential Revision: https://phabricator.services.mozilla.com/D242560
2025-03-26 20:46:45 +00:00
Alexandre Poirot f758c5ec7d Bug 1953957 - [devtools] Stop shipping react-test-renderer-shallow.mjs in Firefox while it is only used in tests. r=devtools-reviewers,nchevobbe
This sizeable file is only used by two tests.
On top of that, we could easily use some other way to test them.

Differential Revision: https://phabricator.services.mozilla.com/D241595
2025-03-19 13:30:51 +00:00
Alexandre Poirot 49e23bea5b Bug 1953578 - [devtools] Migrate all usage of react-dom CommonJS module to the ES Module version and remove the CommonJS version. r=profiler-reviewers,devtools-reviewers,canaltinova,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D241280
2025-03-19 13:30:50 +00:00
Nicolas Chevobbe e1efbae727 Bug 1935431 - Expose TrustedHTML, TrustedScript and TrustedScriptURL in DevTools sandbox. r=devtools-reviewers,smaug.
This is needed to add meaningful previews for instances of those classes in
the console.
Tests are added in next patch.

Differential Revision: https://phabricator.services.mozilla.com/D241357
2025-03-13 15:11:43 +00:00
Alexandre Poirot d589524af0 Bug 1952224 - [devtools] Use Set for react module URIs in devtools loaders. r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D240658
2025-03-10 13:55:12 +00:00
Alexandre Poirot aa6af1d10d Bug 1949588 - [devtools] Remove React non-ESM modules r=nchevobbe,devtools-reviewers
Also introduce a temporary workaround in the base loader to force loading
the available ESM from vendor.
This will prevent significantly increasing firefox installer size.

All the duplicated ESM modules are removed from Firefox package,
but some are kept in-tree for some jest tests which can't use ESM.

Differential Revision: https://phabricator.services.mozilla.com/D239055
2025-03-05 17:06:04 +00:00
Alexandre Poirot abad032e96 Bug 1929387 - [devtools] Ensure loading all callsites of ObjectInspector via a BrowserLoader. r=devtools-reviewers,nchevobbe
This is required as Object Inspector has to be loaded via a document scope
for its ChromeUtils.importESModule + global="current" to be functional.

Differential Revision: https://phabricator.services.mozilla.com/D237739
2025-03-05 17:06:03 +00:00
Alexandre Poirot 8b4e65c0af Bug 1949486 - [devtools] Expose ES Module versions for React modules. r=devtools-reviewers,nchevobbe
Land ES Modules for all React modules.

Also tweak the Browser Loader to force loading react loaded via require() to use the ES Modules.
This helps ensure these modules are loaded only once and always as a ES Module.
Otherwise require() statements from debugger frontend and import from Reps may load
distinct instances.

Differential Revision: https://phabricator.services.mozilla.com/D228995
2025-03-05 17:05:54 +00:00
Alexandre Poirot 2064ac5d14 Bug 1949437 - [devtools] Avoid loading duplicated debugger modules instances. r=devtools-reviewers,bomsy
These modules are already loaded by the Debugger frontend via the browser loader
instantiated in /index.js and we were loading a copy in the shared global loader.

This also helps the esm-ification of Reps as it ensures loading
all debugger modules in the debugger document global.
Reps modules are expected to be loaded with a document as global scope.

Differential Revision: https://phabricator.services.mozilla.com/D237738
2025-02-26 16:35:51 +00:00
Tooru Fujisawa a2b2011774 Bug 1934690 - Stop using global this in worker-loader.sys.mjs. r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D230838
2024-12-03 07:08:47 +00:00
Tooru Fujisawa a7b25dca83 Bug 1934044 - Update obsoleve comments about JSM in devtools. r=devtools-reviewers,ochameau
Differential Revision: https://phabricator.services.mozilla.com/D230562
2024-12-02 21:17:45 +00:00
Julian Descottes 6498ec9ae7 Bug 972821 - [devtools] Support data URLs in netmonitor r=devtools-reviewers,bomsy
Display requests in the netmonitor for data URIs.
Currently, some data-uris are leaking from internal stylesheets such as resource://gre-resources/html.css but this should hopefully be rare.

Another bug has been filed to properly filter out those requests.

A simple test is added to make sure we can see parent process and content process data uris.

Differential Revision: https://phabricator.services.mozilla.com/D217413
2024-11-26 18:36:56 +00:00
Butkovits Atila 79305b06ad Backed out 2 changesets (bug 1932818, bug 972821) for causing failures at browser_keyword.js. CLOSED TREE
Backed out changeset 47548f2ad19d (bug 1932818)
Backed out changeset 5866bcc8111e (bug 972821)
2024-11-26 18:34:32 +02:00
Julian Descottes 118c9ef5b1 Bug 972821 - [devtools] Support data URLs in netmonitor r=devtools-reviewers,bomsy
Display requests in the netmonitor for data URIs.
Currently, some data-uris are leaking from internal stylesheets such as resource://gre-resources/html.css but this should hopefully be rare.

Another bug has been filed to properly filter out those requests.

A simple test is added to make sure we can see parent process and content process data uris.

Differential Revision: https://phabricator.services.mozilla.com/D217413
2024-11-26 13:58:54 +00:00
Florian Quèze f109f4cf1f Bug 1921751 - Migrate telemetry events to use Glean APIs for devtools.main, r=chutten,devtools-reviewers,nchevobbe.
Differential Revision: https://phabricator.services.mozilla.com/D223504
2024-09-30 14:37:48 +00:00
Mark Banner 26216a2205 Bug 1575506 - Enable ESLint rule no-redeclare with builtinGlobals on all module and worker files. r=frontend-codestyle-reviewers,devtools-reviewers,nchevobbe,mossop
Differential Revision: https://phabricator.services.mozilla.com/D221446
2024-09-12 21:08:45 +00:00
Sandor Molnar b59809ee6a Backed out 8 changesets (bug 1917532, bug 1575506, bug 1917530) for causing node newtab failures CLOSED TREE
Backed out changeset 8d6f7bc74d08 (bug 1917532)
Backed out changeset 7c963e72cf06 (bug 1575506)
Backed out changeset d5e110187781 (bug 1917530)
Backed out changeset 1d2325ffded6 (bug 1917530)
Backed out changeset 8a361e37e32c (bug 1917530)
Backed out changeset c4011d92c7f7 (bug 1917530)
Backed out changeset 1a45047dfb3c (bug 1917530)
Backed out changeset ed6b35444c45 (bug 1917530)
2024-09-12 20:45:28 +03:00
Mark Banner a1f8e140ba Bug 1575506 - Enable ESLint rule no-redeclare with builtinGlobals on all module and worker files. r=frontend-codestyle-reviewers,devtools-reviewers,nchevobbe,mossop
Differential Revision: https://phabricator.services.mozilla.com/D221446
2024-09-12 16:41:59 +00:00
Gregory Pappas 5e942dde11 Bug 1546738 - Get rid of the hidden window usage to get a WebSocket object r=ochameau,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D219620
2024-08-21 20:07:14 +00:00
Alexandre Poirot 5eeea2b7d6 Bug 1651518 - [devtools] Enable server side worker targets for browser toolbox. r=devtools-reviewers,nchevobbe
Note that the ignore code for subprocess is being ported from the legacy worker watcher.

The Worker Target URL is now correctly set to the Absolute URL,
this has an impact on the context selector as we are displaying it.

Also, this patch highlights some issues around Common JS Loader and the distinct compartment
to be used when debugging privileged page, or when running the browser toolbox.
It caused leaks when running browser toolbox tests in debug builds.
The JS Process Actor is directly loaded in a distinct global and compartment "DevTools global",
thanks to `loadInDevToolsLoader` flag of BrowserToolboxDevToolsProcess JS Process Actor configuration.
There is no need to use `useDistinctSystemPrincipalLoader` helper as Loader.sys.mjs, loaded from
the JS Process Actor will also be loaded in the distinct global.
Then, we only need to ensure that the CommonJS Loader will also pick up the "DevTools global"
when it is loaded in that distinct global.
Things will be significantly easier once we migrate from CommonJS to ESM as the `{ global: "contextual" }`
option passed to `ChromeUtils.importESModule` will do the right thing, as well as static `import` statements.

Differential Revision: https://phabricator.services.mozilla.com/D204874
2024-05-27 09:53:55 +00:00
Cristian Tuns d0272b92b7 Backed out 8 changesets (bug 1651518, bug 1883847) dt failures in nsTArray.h. CLOSED TREE
Backed out changeset 481558275c1d (bug 1651518)
Backed out changeset 5337435e8bca (bug 1651518)
Backed out changeset 8fe0c1a4da7f (bug 1651518)
Backed out changeset 840a0d9db260 (bug 1651518)
Backed out changeset eaab9de5819d (bug 1651518)
Backed out changeset cf71de92d782 (bug 1651518)
Backed out changeset d778691464db (bug 1651518)
Backed out changeset af28e5f719e8 (bug 1883847)
2024-05-22 09:02:19 -04:00
Alexandre Poirot 76d52e829a Bug 1651518 - [devtools] Enable server side worker targets for browser toolbox. r=devtools-reviewers,nchevobbe
Note that the ignore code for subprocess is being ported from the legacy worker watcher.

The Worker Target URL is now correctly set to the Absolute URL,
this has an impact on the context selector as we are displaying it.

Also, this patch highlights some issues around Common JS Loader and the distinct compartment
to be used when debugging privileged page, or when running the browser toolbox.
It caused leaks when running browser toolbox tests in debug builds.
The JS Process Actor is directly loaded in a distinct global and compartment "DevTools global",
thanks to `loadInDevToolsLoader` flag of BrowserToolboxDevToolsProcess JS Process Actor configuration.
There is no need to use `useDistinctSystemPrincipalLoader` helper as Loader.sys.mjs, loaded from
the JS Process Actor will also be loaded in the distinct global.
Then, we only need to ensure that the CommonJS Loader will also pick up the "DevTools global"
when it is loaded in that distinct global.
Things will be significantly easier once we migrate from CommonJS to ESM as the `{ global: "contextual" }`
option passed to `ChromeUtils.importESModule` will do the right thing, as well as static `import` statements.

Differential Revision: https://phabricator.services.mozilla.com/D204874
2024-05-22 11:50:45 +00:00
Cristina Horotan ca70119cfa Backed out 8 changesets (bug 1651518, bug 1883847) for causing damp failures at toolbox/browser-toolbox.js CLOSED TREE
Backed out changeset 4ec70db12f48 (bug 1651518)
Backed out changeset b2b138889ad6 (bug 1651518)
Backed out changeset efda5c09b0ea (bug 1651518)
Backed out changeset b0de4113f8fb (bug 1651518)
Backed out changeset 03cf235d2a80 (bug 1651518)
Backed out changeset 58e71c27f1fd (bug 1651518)
Backed out changeset f7fb390c3965 (bug 1651518)
Backed out changeset b8a2473c47c0 (bug 1883847)
2024-05-22 04:00:53 +03:00
Alexandre Poirot 64b2f242bc Bug 1651518 - [devtools] Enable server side worker targets for browser toolbox. r=devtools-reviewers,nchevobbe
Note that the ignore code for subprocess is being ported from the legacy worker watcher.

Also, this patch highlights some issues around Common JS Loader and the distinct compartment
to be used when debugging privileged page, or when running the browser toolbox.
It caused leaks when running browser toolbox tests in debug builds.
The JS Process Actor is directly loaded in a distinct global and compartment "DevTools global",
thanks to `loadInDevToolsLoader` flag of BrowserToolboxDevToolsProcess JS Process Actor configuration.
There is no need to use `useDistinctSystemPrincipalLoader` helper as Loader.sys.mjs, loaded from
the JS Process Actor will also be loaded in the distinct global.
Then, we only need to ensure that the CommonJS Loader will also pick up the "DevTools global"
when it is loaded in that distinct global.
Things will be significantly easier once we migrate from CommonJS to ESM as the `{ global: "contextual" }`
option passed to `ChromeUtils.importESModule` will do the right thing, as well as static `import` statements.

Differential Revision: https://phabricator.services.mozilla.com/D204874
2024-05-21 14:09:35 +00:00