Commit Graph
27 Commits
Author SHA1 Message Date
Alexandre Poirot 6bb0053288 Bug 1979680 - [devtools] Revise tabs reducer implementation to prevent many useless state and component updates. r=devtools-reviewers,perftest-reviewers,afinder,bomsy
Move away from having "tab" objects.

Instead focus on bare minimal data.
* Two distinct list of URLs (Array of strings), for all source URLs which should be:
  - opened in tabs (state.tabs.urls)
  - pretty printed (state.tabs.prettyPrintedURLs)
  These two lists are persisted in async storage and re-appliead on page reload and after devtools restarts.
* List of source objects (Array of objects) which are currently displayed in tabs (state.tabs.openedSources).
  This list is transient and cleared on page reload.

This simplify lots of logics as this is now URL and source based.
Also, we don't need to store the precise `sourceActor` selected by the tab as it only display source information.

Differential Revision: https://phabricator.services.mozilla.com/D259173
2025-09-03 23:14:42 +00:00
Holger Benl 36984e586b Bug 1894630 - [devtools] Persist the directory root per origin. r=nchevobbe,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D245263
2025-04-22 14:03:52 +00:00
Norisz Fay 8b02ae61da Backed out 2 changesets (bug 1887872) for causing dt failures on browser_dbg-old-breakpoint.js CLOSED TREE
Backed out changeset b32b818f2175 (bug 1887872)
Backed out changeset 705494857aed (bug 1887872)
2024-03-27 21:22:10 +02:00
Alexandre Poirot 1ec9670095 Bug 1887872 - [devtools] Set breakpoints on toolbox opening. r=devtools-reviewers,devtools-backward-compat-reviewers,bomsy
Register them as soon as we open devtools, instead of waiting for debugger panel opening.
So that breakpoints can work even if we did not open debugger panel yet.
So far, only debugger statement would force the opening of the debugger.

This allows to remove the redundant code from debugger frontend.

Also clarify in this patch that thread-utils exports thread configurations.

Differential Revision: https://phabricator.services.mozilla.com/D205772
2024-03-27 17:04:34 +00:00
Alexandre Poirot c867832007 Bug 1789981 - [devtools] Convert last DevTools JSM to ESM. r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D202438
2024-03-26 08:29:22 +00:00
Alexandre Poirot 564a6404bd Bug 1578220 - [devtools] Allow disabling debugger statement by a toggle in the breakpoints panel. r=devtools-reviewers,nchevobbe
This toggle is checked by default so that debugger statements are still enabled by default.
As for other settings, this is preserved on restart so that it is handy for users willing to
always keep them disabled. But it may be an annoyance for others forgetting that they once disabled them.

Differential Revision: https://phabricator.services.mozilla.com/D193431
2023-11-17 16:05:04 +00:00
Cosmin Sabou 8401528d8e Backed out 2 changesets (bug 1834296) for dt failures on browser_dbg-breakpoints-enable-and-disable.js.
Backed out changeset e16305b72dc9 (bug 1834296)
Backed out changeset b5427bcae296 (bug 1834296)
2023-06-13 17:37:56 +03:00
Hubert Boma Manilla 52ec016d14 Bug 1834296 - [devtools] Do not call setBreakpoints for disabled breakpoints on a reconfigure r=ochameau,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D179898
2023-06-13 12:54:02 +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
Alexandre Poirot 567e3cd0c3 Bug 1831358 - [devtools] Remove debugger overlay preferences. r=devtools-reviewers,bomsy
The second preference wasn't used.
Otherwise the "overlay" preferences should be considered the default behavior.

Differential Revision: https://phabricator.services.mozilla.com/D177207
2023-05-09 11:47:44 +00:00
Alexandre Poirot a85b82697f Bug 1792847 - [devtools] Use absolute URLs to import modules in devtools/client/shared. r=jdescottes,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D158379
2022-09-30 15:17:39 +00:00
Alexandre Poirot 58b38d7c16 Bug 1791969 - [devtools] Import all JSM in DevTools via ChromeUtils.import. r=jdescottes
Convert all imports but the one related to SessionDataHelper
as that's an hybrid module which is loaded as a JSM from the main thread,
but loaded as a common js module from the worker thread.

We will be able to drop this once we can migrate this JSM to ESM
once we support loading ESM from the worker thread.

Differential Revision: https://phabricator.services.mozilla.com/D158007
2022-09-26 13:01:33 +00:00
Alexandre Poirot 13775af5a0 Bug 1791969 - [devtools] Import all JSMs in DevTools with absolute URIs. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D158006
2022-09-26 13:01:33 +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
Alexandre Poirot d654450f9d Bug 1719615 - [devtools] Enable 'observeWasm' only once the debugger is opened. r=yury,bomsy
Because WASM debugging triggers different machine code with debugging instruction,
the memory usage very significantly increase.
So avoid enabling it until the debugger is opened.

Differential Revision: https://phabricator.services.mozilla.com/D140069
2022-03-24 21:03:41 +00:00
Yury Delendik 250936f571 Bug 1719615 - Add observeWasm in addition to observeAsmJS. r=lth
Differential Revision: https://phabricator.services.mozilla.com/D123626
2022-03-24 21:03:41 +00:00
Hubert Boma Manilla 52eceed385 Bug 1745940 - [devtools] Add blackbox line support for actions and reducers r=ochameau
This patch includes the following:-
- The reducer logic to store the blackbox url and range info matches that on the
  server here https://searchfox.org/mozilla-central/rev/dfc0dea63a16b73078a46b6ae49b2a626b8c11b5/devtools/server/actors/utils/sources-manager.js#289-335
  Note: The client logic supports multiple ranges whhile the server supports one range (maybe we can add support for multiple to the server).
- Added jest tests for some edge cases
- Changed the asyncStore pref from `tabsBlackBoxed` to `blackboxedTabs` for readability ease
  and to avoid and errors as the format of the data stored changes.

  Before: `asyncStore.tabsBlackBoxed = ["foo.com", "bar.com"...]`
  After:  `asyncStore.blackboxedTabs = { "foo.com": [], "bar.com": [range, range, ...] }`


  The range sturcture

  ```
  const range = {
    start: { line: 1, column: 5 },
    end: { line: 3, column: 4 },
  }
  ```

Differential Revision: https://phabricator.services.mozilla.com/D132774
2021-12-16 23:53:26 +00:00
Alexandre Poirot 2f6f110666 Bug 1720512 - [devtools] Avoid storing and restoring broken breakpoints. r=jdescottes,bomsy
This is a bit surprising that broken breakpoints are stored
as the frontend seems to try to do a couple of assertions:
https://searchfox.org/mozilla-central/rev/c0fc8c4852e927b0ae75d893d35772b8c60ee06b/devtools/client/debugger/src/utils/breakpoint/index.js#84-106

But at least, now, we start using same assertions in both sides.

Differential Revision: https://phabricator.services.mozilla.com/D120002
2021-07-19 15:30:34 +00:00
Alexandre Poirot c920b4d1a4 Bug 1654587 - [devtools] Use a shared asyncStore instance between Debugger Frontend and TargetMixin. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D91736
2020-09-30 17:42:28 +00:00
Jason Laster 7e22b879d1 Bug 1633727 - Always attach thread front from toolbox code. r=ochameau,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D75157
2020-07-28 19:44:38 +00:00
Jason Laster a91d886635 Bug 1644813 - Remove references to autoBlackbox. r=loganfsmyth
Differential Revision: https://phabricator.services.mozilla.com/D79167
2020-06-12 18:06:42 +00:00
Jason Laster ee375e0fec Bug 1616322 - Update Async Stack UI.
Differential Revision: https://phabricator.services.mozilla.com/D63212
2020-02-26 06:24:04 +00:00
Logan Smyth 2b017e1cf1 Bug 1592430 - Basic support for async live stacks in the debugger server. r=jimb
Differential Revision: https://phabricator.services.mozilla.com/D56661
2019-12-12 06:19:03 +00:00
Jason Laster 60e53aaebd Bug 1594941 - Remove unused Frame.environment field. r=bhackett
Differential Revision: https://phabricator.services.mozilla.com/D53851
2019-11-19 19:53:14 +00:00
Andreea Pavel e978a84b45 Backed out changeset 352bd579f519 (bug 1594941) for failing xpcshell at test_breakpoint-16.js on a CLOSED TREE 2019-11-19 20:56:26 +02:00
Jason Laster 8da3c0ae3a Bug 1594941 - Remove unused Frame.environment field. r=bhackett
Differential Revision: https://phabricator.services.mozilla.com/D52282
2019-11-19 15:44:58 +00:00
Brian Hackett 1bf0b6ad0e Bug 1583671 - Allow pausing on exceptions in workers, r=jlast.
Differential Revision: https://phabricator.services.mozilla.com/D47320
2019-10-01 15:07:45 +00:00