Commit Graph
20 Commits
Author SHA1 Message Date
Mark Banner aefd647018 Bug 1881265 - Enable ESLint recommended rule getter-return. r=mossop,extension-reviewers,devtools-reviewers,omc-reviewers,nchevobbe,aminomancer,robwu
Differential Revision: https://phabricator.services.mozilla.com/D202318
2024-02-26 11:35:40 +00:00
Alexandre Poirot ba9bf188e6 Bug 1578975 - [devtools] Remove now-unused setupInParent code. r=devtools-reviewers,jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D166695
2023-01-29 20:50:48 +00:00
Mark Banner d143a73ba5 Bug 1808500 - Automatically replace Cu.reportError with console.error (devtools). r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D165941
2023-01-06 15:34:27 +00:00
Alexandre Poirot f34cb064e0 Bug 1721592 - [devtools] Remove DevToolsServerConnection.spawnActorInParentProcess. r=devtools-reviewers,jdescottes
This was only used by legacy netmonitor class.

Differential Revision: https://phabricator.services.mozilla.com/D165606
2023-01-04 18:27:21 +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 28d340da28 Bug 1792849 - [devtools] Use absolute URLs to import modules in devtools/server. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D158487
2022-10-03 18:57:12 +00:00
Alexandre Poirot 3f479154b1 Bug 1276347 - [devtools] Remove "reportError" from devtools module globals. r=jdescottes
This might have only be useful from the source actor.
In workers, you don't have access to Cu, so nor have access to Cu.reportError.
Otherwise from the main thread, you can safely use Cu.reportError.

In couple of places I'm removing the usage of reportError.
Hopefully throwing an exception is enough to get the error displayed!

Differential Revision: https://phabricator.services.mozilla.com/D157909
2022-09-26 10:48:04 +00:00
Mark Banner 6d03c63e2d Bug 1330099 - Enable object-shorthand eslint rule. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D153567
2022-08-03 14:57:05 +00:00
Nicolas Chevobbe 97f04b57b0 Bug 1781726 - [devtools] Pass an isModeSwitching property to onTargetDestroyed callback param when switching modes. r=jdescottes,devtools-backward-compat-reviewers.
We pass `isModeSwitching` to `unwatchTargets` from the target command when the
pref is changed.
On the server, we then pass it to the various places which might call `notifyTargetDestroyed`,
so we can pass the flag in the `target-destroyed-form` event, which we can then
pass to TargetCommand#onDestroyed callbacks.`

Differential Revision: https://phabricator.services.mozilla.com/D152758
2022-07-29 14:30:07 +00:00
Alexandre Poirot 3c4356b16b Bug 1699111 - [devtools] Rename transports onClosed callback to onTransportClosed. r=jdescottes
This will better highlight what is closing. Not the DevToolsClient, but just the transport class.

Differential Revision: https://phabricator.services.mozilla.com/D108812
2021-04-13 13:44:24 +00:00
Julian Descottes e875cc4076 Bug 1633727 - Improve error reporting for legacy actors r=nchevobbe
Depends on D75157

A thread actor attach error shows up as
  Protocol error (unknownError): error occurred while processing 'attach':
  [object Object] from: server0.conn145.content-process36/workerTarget5/thread1

[object Object] is a legacy {error, message} object thrown by the thread actor

Differential Revision: https://phabricator.services.mozilla.com/D83507
2020-07-28 19:44:51 +00:00
Nicolas Chevobbe 6d31eeb842 Bug 1623283 - Rename Pool#actor into getActorByID. r=jdescottes.
We take this opportunity to remove Pool.get as well,
which was doing exactly the same thing as Pool.actor

This highlighted a couple issues in Reps:
- LongString were relying on the isGrip function, which was only checking that
  the actor property was truthy. So it was matching LongStringFront which had
  the actor method. This is modified by using the isLongString helper instead.
- The Object rep was building all the reps for the object properties, even in
  TINY mode, where the result was only used to check the length. In the Accessibility
  panel, it can happen that an plain object containing front properties is passed
  to Rep. It was fine before because this was short-circuited by the Accessor rep
  which was only checking the truthiness of a `get` property. With `get` being
  removed, the default Rep was used, which is Object, and we were hitting a
  recursion loop, as some of the properties of fronts are cycle references.
  There should be a fix in the Accessibility panel to _not_ pass fronts, but we
  also "fix" it from here by simply not building sub-properties for the object
  when we're in TINY mode.

Differential Revision: https://phabricator.services.mozilla.com/D81971
2020-07-02 15:07:12 +00:00
Nicolas Chevobbe a1d55c9cf5 Bug 1495728 - Remove unused ActorPool class. r=ochameau.
This class isn't used anymore, and it's safe to remove it.
We take this as an opportunity to remove Pool#cleanup and
Pool#isEmpty, which each only had one callsite.
Some comments are updated to not mention ActorPool.

Differential Revision: https://phabricator.services.mozilla.com/D80602
2020-06-24 07:39:06 +00:00
Julian Descottes 34ae8de079 Bug 1646456 - Only call destroy on top level pools from connection onClosed r=ochameau,nchevobbe
Depends on D80060

Differential Revision: https://phabricator.services.mozilla.com/D80064
2020-06-23 11:08:30 +00:00
Julian Descottes a0145e6ba0 Bug 1646456 - Remove unused noCleanup argument from removeActorPool r=nchevobbe
Depends on D80059

removeActorPool is only called from one spot, which always passes the second optional argument as true.

Differential Revision: https://phabricator.services.mozilla.com/D80060
2020-06-22 12:54:26 +00:00
Alexandre Poirot 123ea13e79 Bug 1620243 - Watch console messages resources from the server side. r=nchevobbe,jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D77441
2020-06-09 18:22:45 +00:00
Jason Laster a936c33489 Bug 1622116 - Add a helper for visualizing server pools. r=ochameau
Differential Revision: https://phabricator.services.mozilla.com/D66687
2020-04-08 17:33:12 +00:00
Jason Laster 3694ec93d0 Bug 1622996 - Refactor devtools codebase to use optional chaining (automated changes). r=jdescottes
Depends on D67084

Differential Revision: https://phabricator.services.mozilla.com/D67537
2020-03-19 21:13:38 +00:00
Mark Banner 1cc76add79 Bug 1620218 - Automatic code fixes for Prettier 1.18.2 upgrade. r=mossop,webcompat-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D65509
2020-03-08 21:45:16 +00:00
Alexandre Poirot 2199c34392 Bug 1614793 - Rename DebuggerServerConnection to DevToolsServerConnection. r=jdescottes
Most of this was already done in bug 1614791, but we still have
to rename the file and change the require path.

Differential Revision: https://phabricator.services.mozilla.com/D63189
2020-02-18 15:28:49 +00:00