Commit Graph
554 Commits
Author SHA1 Message Date
Julian Descottes de8604d428 Bug 1913472 - [devtools] Fix propTypes warnings when using the console r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D219339
2024-08-16 13:44:11 +00:00
Emilio Cobos Álvarez a898423415 Bug 1902896 - Remove unnecessary fallback font family. r=devtools-reviewers,nchevobbe
system-ui should be enough. It's also equivalent to -apple-system on
macOS right now.

Differential Revision: https://phabricator.services.mozilla.com/D213881
2024-06-17 10:50:34 +00:00
Nicolas Chevobbe e249389848 Bug 1844087 - [devtools] Make SearchBox input described by summary element. r=devtools-reviewers,accessibility-frontend-reviewers,ochameau,ayeddi.
This should allow the number of hidden messages to be notified to
screen reader users.
We update the Console FilterBar behavior to always show the "X hidden" message
when the input is focused, so screen reader can also pick up when no messages
are hidden.

Differential Revision: https://phabricator.services.mozilla.com/D213181
2024-06-17 06:31:26 +00:00
Nicolas Chevobbe 8a13e46e2e Bug 1901942 - [devtools] Remove unused FilterCheckbox component. r=devtools-reviewers,jdescottes.
Differential Revision: https://phabricator.services.mozilla.com/D213391
2024-06-12 11:54:38 +00:00
Nicolas Chevobbe e39b6ccdc1 Bug 1897139 - [devtools] Share blocked request string between console and netmonitor. r=devtools-reviewers,ochameau.
Differential Revision: https://phabricator.services.mozilla.com/D210649
2024-05-17 07:42:17 +00:00
Nicolas Chevobbe e58349d131 Bug 1895536 - [devtools] Update network request blocked string. r=devtools-reviewers,ochameau.
Requests can be blocked because of many reasons, but the label was always
saying it was because of DevTools.
Update the label so we follow what's done in Netmonitor.

Differential Revision: https://phabricator.services.mozilla.com/D210471
2024-05-16 12:40:22 +00:00
Nicolas Chevobbe 468323a509 Bug 1888645 - [devtools] Fix SmartTrace crash with wasm frames. r=devtools-reviewers,bomsy.
In some cases, we were getting null sourceId, which was causing an exception
to be thrown in `getFormattedSourceId` since it expects a string.
We add a simple guard in this function so we don't throw anymore.

But we shouldn't get null sourceId in the first place. It looks like for
some Wasm sources, the SavedFrame sourceId can be 0, which wasn't playing
well with some loose check we were doing in the sources manager.

Finally, the "Copy metadata" button we display when a console message crash
wasn't working. The message now includes the targetFront, which can be serialized
in JSON, so we simply ignore it.

Differential Revision: https://phabricator.services.mozilla.com/D206105
2024-05-13 10:17:15 +00:00
Alexandre Poirot 8c9338e858 Bug 1827382 - [devtools] Migrate tracer from JSM to ESM. r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D202437
2024-03-26 08:29:21 +00:00
Alexandre Poirot d22ddaa6e6 Bug 1884717 - [devtools] Only log "returns" when logging exit frames without tracing values. r=devtools-reviewers,bomsy
We were logging "returns undefined" everywhere.

Differential Revision: https://phabricator.services.mozilla.com/D204301
2024-03-13 13:48:54 +00:00
Dave Townsend 2af4d349f3 Bug 1864896: Autofix unused function arguments (devtools). r=profiler-reviewers,devtools-reviewers,nchevobbe,julienw
Differential Revision: https://phabricator.services.mozilla.com/D202959
2024-03-05 14:21:15 +00:00
Gregory Pappas 67bf0fdf61 Bug 1878401 - part 4 - Update nsIFilePicker users in devtools/ to pass BrowsingContext to init r=profiler-reviewers,devtools-reviewers,nchevobbe,julienw
Depends on D200548

Differential Revision: https://phabricator.services.mozilla.com/D200549
2024-02-28 21:29:38 +00:00
Sandor Molnar c853f2f3e9 Backed out 8 changesets (bug 1878401, bug 1879041) for causing build bustages on widget/nsBaseFilePicker.cpp CLOSED TREE
Backed out changeset 2e2b8df3bdd6 (bug 1879041)
Backed out changeset 6d6952f9df2c (bug 1878401)
Backed out changeset 30b5bb590d3e (bug 1878401)
Backed out changeset 9a4b830334b9 (bug 1878401)
Backed out changeset 3c3d67f1fcb7 (bug 1878401)
Backed out changeset c83ba4026822 (bug 1878401)
Backed out changeset 6bcb670ce475 (bug 1878401)
Backed out changeset f263b196df96 (bug 1878401)
2024-02-28 17:56:48 +02:00
Gregory Pappas 19820007ba Bug 1878401 - part 4 - Update nsIFilePicker users in devtools/ to pass BrowsingContext to init r=profiler-reviewers,devtools-reviewers,nchevobbe,julienw
Depends on D200548

Differential Revision: https://phabricator.services.mozilla.com/D200549
2024-02-28 15:07:45 +00:00
Alexandre Poirot 8fd4e3f6d4 Bug 1721427 - [devtools] Trace each step in a function call. r=devtools-reviewers,nchevobbe
This feature is only exposed to internal usages of tracer.jsm, by passing traceStep boolean option:
```
startTracing({ global, traceSteps: true });
```
This will automatically log to stdout all traces, including each frame step within a function execution.
Without this flag, the tracer would only trace function calls and nothing more.
We would not know which line is being executed within the function execution.

Differential Revision: https://phabricator.services.mozilla.com/D201977
2024-02-27 14:52:12 +00:00
Alexandre Poirot de907e9f52 Bug 1879087 - [devtools] Trace DOM mutations. r=devtools-reviewers,nchevobbe
Also allow logging trace whenever any DOM Element get added, removed or modified.
For now this is exposed only via the console command via:
  :tracer --dom-mutations  (for all types of mutation)
  :tracer --dom-mutations add,attributes,remove (coma separated list of mutation types you want to listen for)

Also revise the handling of "isWorker" so that all checks have the best possible check.

Differential Revision: https://phabricator.services.mozilla.com/D201976
2024-02-22 08:52:21 +00:00
Mark Banner b5df22ad0f Bug 1880535 - Enable ESLint rule no-unused-private-class-members. r=Gijs,webdriver-reviewers,webcompat-reviewers,extension-reviewers,application-update-reviewers,devtools-reviewers,translations-reviewers,bytesized,twisniewski,jhirsch,robwu,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D202002
2024-02-20 22:09:21 +00:00
Alexandre Poirot d42ef20edd Bug 1852028 - [devtools] Log function return in javascript tracer. r=devtools-reviewers,nchevobbe
For now, we were only logging when we enter a function call, but not when we exit.

Differential Revision: https://phabricator.services.mozilla.com/D200173
2024-02-13 09:38:50 +00:00
Alexandre Poirot 6fc6849dbd Bug 1848159 - [devtools] Use tracing icon for all messages related to the tracing. r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D199975
2024-01-30 20:18:51 +00:00
Alexandre Poirot fd5a144115 Bug 1873066 - [devtools] Avoid some computation when receiving new messages. r=devtools-reviewers,nchevobbe
The "is in opening group" computation, which goes through all message arrays
can be avoided until it is meaningful to check for this particular edge case.
Also we can remove the redundant check against `nextProps.messagesUi`.

Differential Revision: https://phabricator.services.mozilla.com/D197770
2024-01-17 15:10:46 +00:00
Nicolas Chevobbe 5a608228ab Bug 1872689 - [devtools] Prepare codebase for eslint-plugin-react update. r=devtools-reviewers,ochameau.
Updating eslint-plugin-react to 7.33.2 raises new eslint errors.
A few component needed to have their proptypes fixed (or added).
JSPropertyProvider was considered as a react component by the plugin,
I guess because it is a function starting with an uppercase letter.
Since it is a bit unusual to have such thing, I renamed it slightly
to make it look more like a function.

Differential Revision: https://phabricator.services.mozilla.com/D197596
2024-01-04 16:06:08 +00:00
Alexandre Poirot 641c35b909 Bug 1835614 - [devtools] Use a custom resource for traces. r=devtools-reviewers,nchevobbe
This help reduce the RDP overhead by only transferring what is strictly necessary.
The console message resources bundles various useless attributes.

This also help use a custom rendering in the frontend so that traces can
be displayed distinctly and differently from the console API calls.

Differential Revision: https://phabricator.services.mozilla.com/D196020
2023-12-19 18:01:52 +00:00
Narcis Beleuzu 54a3764889 Backed out 2 changesets (bug 1835614) for xpcshell failure on test_tracer.js . CLOSED TREE
Backed out changeset 4501d1fb176a (bug 1835614)
Backed out changeset 60b933696a41 (bug 1835614)
2023-12-19 12:54:32 +02:00
Alexandre Poirot 193fc9986e Bug 1835614 - [devtools] Use a custom resource for traces. r=devtools-reviewers,nchevobbe
This help reduce the RDP overhead by only transferring what is strictly necessary.
The console message resources bundles various useless attributes.

This also help use a custom rendering in the frontend so that traces can
be displayed distinctly and differently from the console API calls.

Differential Revision: https://phabricator.services.mozilla.com/D196020
2023-12-19 09:20:33 +00:00
Hubert Boma Manilla aae1a14a42 Bug 1858076 - [devtools] Show notification in the console when original variable mapping is disabled r=devtools-reviewers,nchevobbe
This patch displays a notification in the console when the debugger is paused
in an original file with original variable mapping is turned off.

The notification is displayed when console input is focused, also if the user selects
a generated file, or is no longer paused or switches on varaible mapping, the notification is removed
once the console input is refocused.

Also added support for specific notifications to control displaying the close button.

Differential Revision: https://phabricator.services.mozilla.com/D191568
2023-11-14 07:35:49 +00:00
Sandor Molnar bcd249053b Backed out 4 changesets (bug 1858652, bug 1858032, bug 1858076, bug 1856270) for causing talos damp failures
Backed out changeset 569b6a151d3e (bug 1858076)
Backed out changeset 3c66fbe494de (bug 1858652)
Backed out changeset 966ce8c9e339 (bug 1858032)
Backed out changeset 3e08029e8f01 (bug 1856270)
2023-11-08 07:21:25 +02:00
Hubert Boma Manilla 513736cd5d Bug 1858076 - [devtools] Show notification in the console when original variable mapping is disabled r=devtools-reviewers,nchevobbe
This patch displays a notification in the console when the debugger is paused
in an original file with original variable mapping is turned off.

The notification is displayed when console input is focused, also if the user selects
a generated file, or is no longer paused or switches on varaible mapping, the notification is removed
once the console input is refocused.

Also added support for specific notifications to control displaying the close button.

Differential Revision: https://phabricator.services.mozilla.com/D191568
2023-11-07 19:51:31 +00:00
Iulian Moraru e0636fa387 Backed out 4 changesets (bug 1856270, bug 1858652, bug 1858032, bug 1858076) for causing dt failures on browser_dbg-reducer-cleanup-on-target-removal.js. CLOSED TREE
Backed out changeset 492052d366fe (bug 1858076)
Backed out changeset a5a765a10588 (bug 1858652)
Backed out changeset 7797ecc20515 (bug 1858032)
Backed out changeset b8a3c66f7fdc (bug 1856270)
2023-11-06 17:54:12 +02:00
Hubert Boma Manilla a52a4207b0 Bug 1858076 - [devtools] Show notification in the console when original variable mapping is disabled r=devtools-reviewers,nchevobbe
This patch displays a notification in the console when the debugger is paused
in an original file with original variable mapping is turned off.

The notification is displayed when console input is focused, also if the user selects
a generated file, or is no longer paused or switches on varaible mapping, the notification is removed
once the console input is refocused.

Also added support for specific notifications to control displaying the close button.

Differential Revision: https://phabricator.services.mozilla.com/D191568
2023-11-06 14:00:53 +00:00
Nicolas Chevobbe 27a299dc67 Bug 1855200 - [devtools] Fix and harmonize focus indicator across the toolbox. r=devtools-reviewers,ochameau.
The new focus indicator is bigger and has a better contrast, making it more accessible
than the thin dotted line we had previously.
It also includes a white box-shadow so even on our blue "active/selected" backgrounds,
the indicator is still visible (e.g. in the markup view, for a selected node, with
focus on badges / text inputs).

Finally, I tried to go over the elements of the shared components and most used
panels to adjust the outline offset when it was not visible/clipped, or when
it could be conflated with the focused element border/background.

Differential Revision: https://phabricator.services.mozilla.com/D192185
2023-11-03 10:05:53 +00:00
Nicolas Chevobbe 02ab693cc9 Bug 1844093 - [devtools] Better contrast on eager evaluation results. r=devtools-reviewers,ochameau.
Don't override all colors to turn them (insufficiently contrasted) grey,
but apply a desaturate filter which should keep a good enought contrast.

Differential Revision: https://phabricator.services.mozilla.com/D190551
2023-10-11 08:01:26 +00:00
Nicolas Chevobbe 9a88c4becd Bug 1844091 - [devtools] Add proper labels to evaluation and evaluation result message icons. r=devtools-reviewers,ochameau.
Differential Revision: https://phabricator.services.mozilla.com/D189332
2023-09-29 05:23:22 +00:00
Zachary Svoboda 824d105a3d Bug 1673582 - Introduce theme-link-color for better contrast on devtools links r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D187863
2023-09-19 07:00:47 +00:00
Mark Banner 0666077666 Bug 1826062 - Automatic fixes for upgrading Prettier to 2.8.8. r=mossop,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,denschub,devtools-reviewers,sparky,calu
Differential Revision: https://phabricator.services.mozilla.com/D177027
2023-05-20 12:26:53 +00:00
Mark Banner 91fde42f7b Bug 1826062 - Automatic fixes for Prettier 2.0.5 upgrade. r=mossop,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,denschub,devtools-reviewers,sparky,owlish
Differential Revision: https://phabricator.services.mozilla.com/D177025
2023-05-20 12:26:49 +00:00
Nicolas Chevobbe 02a1214926 Bug 1829100 - [devtools] Prevent navigation from network message link. r=bomsy,devtools-reviewers.
Differential Revision: https://phabricator.services.mozilla.com/D176152
2023-04-24 12:21:39 +00:00
Alexandre Poirot 187a45e360 Bug 1803616 - [devtools] Implement a Javascript Tracer in the debugger. r=devtools-reviewers,devtools-backward-compat-reviewers,nchevobbe
On the server side, this patch introduces:
* a new "tracer" Target Scope actor to start and stop tracing per target
* a new TRACING_STATE resource in order to report to the client when we start/stop tracing and with which log method.

On the frontend side, this patch introduces:
* a global tracer button, which will enable/disable tracing for all targets/threads
  all at once.
* a global header, similar to pause, reporting if any target is tracing or not.
The header reuses the pause header and we may want to followup to better coordinate case
where we pause and trace at the same time. Only one of the two states is displayed.

We may want to followup here to be able to trace only one target and see the state per target.

Differential Revision: https://phabricator.services.mozilla.com/D163614
2023-03-14 17:17:05 +00:00
Nicolas Chevobbe 92a3841e6a Bug 1688001 - Allow to open url from network message from keyboard. r=bomsy.
Use a proper link element so it can be focused and clicked.

Differential Revision: https://phabricator.services.mozilla.com/D169349
2023-02-13 10:18:04 +00:00
Nicolas Chevobbe 53f5c8f278 Bug 1815646 - [devtools] Remove odd/even classes on ConsoleTable <tr>. r=bomsy.
Differential Revision: https://phabricator.services.mozilla.com/D169183
2023-02-09 10:01:05 +00:00
Nicolas Chevobbe a8fb4b6283 Bug 1814855 - [devtools] Better message layout on narrow console output. r=bomsy.
First, we set the max-width of the message location in percentage
instead of vw, as the console output inline-size can be different
than the viewport one (e.g. when it is in editor mode).
We then turn the media query we had to hide the timestamp into a
container query, again, to take into account editor mode.
Finally, we place the location on its own row when the output is
narrow so the message text itself can still be readable.

Differential Revision: https://phabricator.services.mozilla.com/D168778
2023-02-06 07:48:04 +00:00
Christian Sonne ec93963f4a Bug 1572777 - Make output of console.table() use an actual table, so it can be pasted into a spreadsheet r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D144513
2023-02-03 13:40:47 +00:00
Nicolas Chevobbe f6f12551fd Bug 1809385 - [devtools] Clear autocomplete cache data on evaluation context change. r=ochameau.
Differential Revision: https://phabricator.services.mozilla.com/D166418
2023-01-10 12:37:19 +00:00
Alexandre Poirot a3e1f8fb52 Bug 1693495 - [devtools] Implement a beginning of "Network" commands, starting with sendHTTPRequest. r=devtools-reviewers,nchevobbe
Use new "commands" thunk argument.
We were passing connector as argument whereas we could have fetched it from thunk arguments.

This will help slowly convert Connector/NetMonitorAPI to a command.

Differential Revision: https://phabricator.services.mozilla.com/D166055
2023-01-09 13:09:43 +00:00
Alexandre Poirot 68cd0b8720 Bug 1693495 - [devtools] Remove getTabTarget in favor of Connector.currentTarget. r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D166053
2023-01-09 13:09:42 +00:00
Alexandre Poirot e1ce06e74c Bug 1806405 - [devtools] Remove code related to "show content message" toggle. r=perftest-reviewers,nchevobbe,kshampur
This was no longer implemented/shown in the fission browser toolbox.
Now that we removed the non-fission toolbox, we can remove this feature.
Instead, content process messages are shown/hidden depending on browser toolbox's scope.
"everything" will show them. "parent-process" won't.

Differential Revision: https://phabricator.services.mozilla.com/D165026
2022-12-20 19:30:30 +00:00
Alexandre Poirot 2c8165afbf Bug 1625939 - [devtools] Remove devtools.browsertoolbox.fission preference and remove old non-fission Browser Toolbox. r=nchevobbe,fluent-reviewers,flod,perftest-reviewers,kshampur
Differential Revision: https://phabricator.services.mozilla.com/D164699
2022-12-20 10:16:48 +00:00
Nicolas Chevobbe 0cdb5fda1f Bug 1804384 - [devtools] Fix indent of messages in warning group. r=bomsy.
Differential Revision: https://phabricator.services.mozilla.com/D164044
2022-12-09 07:08:47 +00:00
Alexandre Poirot 59fe57c052 Bug 1793396 - [devtools] Use absolute URLs in all usages of loader.lazyRequireGetter. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D158489
2022-10-03 18:57:13 +00:00
Alexandre Poirot 465fac9684 Bug 1792847 - [devtools] Use absolute URLs to import modules in devtools/client/webconsole. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D158380
2022-09-30 15:17:40 +00:00
Alexandre Poirot 0f32f335e3 Bug 1789201 - [devtools] Expose Services as a global to all DevTools modules. r=perftest-reviewers,nchevobbe,julienw,AlexandruIonescu
This will help transition to ES Modules as this symbol is exposed to them.

$ sed -ie "/require(.Services.)/d" $(git grep -l 'require("Services")' devtools/)
$ sed -ie "/loader.lazyRequireGetter(this, .Services./d" $(git grep -l 'loader.lazyRequireGetter(this, "Services"' devtools/)
+ the edition of builtin-modules.js + eslintrc.js
+ manual eslint fixes
+ removal of devtools-services in the debugger, except for jest tests

Differential Revision: https://phabricator.services.mozilla.com/D156401
2022-09-09 07:22:51 +00:00
Mark Banner 3387a89bc7 Bug 1786197 - Turn on ESLint rule for prefer-boolean-length-check for devtools. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D155167
2022-08-26 13:39:34 +00:00