Backed out 2 changesets (bug 1544976) for causing xpcshell failures in devtools/client/memory/test/unit/test_action_diffing_02.js
authorshindli <shindli@mozilla.com>
Tue, 30 Apr 2019 04:37:53 +0300
changeset 530701 618d85aa18ee8402d69354e4980939fb89521436
parent 530667 a7ff9b445c9c131ec5d51d3686090bd67a24d815
child 530702 ce9c122d9c32087f63c8d5a053cb24c97a546bbe
push id11265
push userffxbld-merge
push dateMon, 13 May 2019 10:53:39 +0000
treeherdermozilla-beta@77e0fe8dbdd3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1544976
milestone68.0a1
backs out30b551b1a2122b0c4478b3eeb790a96204d4cfcf
1ebc89e3ad9757e2c921ff78670637b7147e0037
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Backed out 2 changesets (bug 1544976) for causing xpcshell failures in devtools/client/memory/test/unit/test_action_diffing_02.js Backed out changeset 30b551b1a212 (bug 1544976) Backed out changeset 1ebc89e3ad97 (bug 1544976)
devtools/client/debugger/src/client/firefox/workers.js
devtools/shared/ThreadSafeDevToolsUtils.js
devtools/shared/flags.js
devtools/shared/fronts/targets/target-mixin.js
devtools/shared/preferences/devtools-shared.js
--- a/devtools/client/debugger/src/client/firefox/workers.js
+++ b/devtools/client/debugger/src/client/firefox/workers.js
@@ -21,39 +21,33 @@ export async function updateWorkerClient
   if (!supportsWorkers(tabTarget)) {
     return {};
   }
 
   const newWorkerClients = {};
 
   const { workers } = await tabTarget.listWorkers();
   for (const workerTargetFront of workers) {
-    try {
-      await workerTargetFront.attach();
-      const [, workerThread] = await workerTargetFront.attachThread(options);
+    await workerTargetFront.attach();
+    const [, workerThread] = await workerTargetFront.attachThread(options);
 
-      const actor = workerThread.actor;
-      if (workerClients[actor]) {
-        if (workerClients[actor].thread != workerThread) {
-          console.error(`Multiple clients for actor ID: ${workerThread.actor}`);
-        }
-        newWorkerClients[actor] = workerClients[actor];
-      } else {
-        addThreadEventListeners(workerThread);
-        workerThread.resume();
+    if (workerClients[workerThread.actor]) {
+      if (workerClients[workerThread.actor].thread != workerThread) {
+        throw new Error(`Multiple clients for actor ID: ${workerThread.actor}`);
+      }
+      newWorkerClients[workerThread.actor] = workerClients[workerThread.actor];
+    } else {
+      addThreadEventListeners(workerThread);
+      workerThread.resume();
 
-        const consoleFront = await workerTargetFront.getFront("console");
-        await consoleFront.startListeners([]);
+      const consoleFront = await workerTargetFront.getFront("console");
+      await consoleFront.startListeners([]);
 
-        newWorkerClients[actor] = {
-          url: workerTargetFront.url,
-          thread: workerThread,
-          console: consoleFront
-        };
-      }
-    } catch (e) {
-      // If any of the workers have terminated since the list command initiated
-      // then we will get errors. Ignore these.
+      newWorkerClients[workerThread.actor] = {
+        url: workerTargetFront.url,
+        thread: workerThread,
+        console: consoleFront
+      };
     }
   }
 
   return newWorkerClients;
 }
--- a/devtools/shared/ThreadSafeDevToolsUtils.js
+++ b/devtools/shared/ThreadSafeDevToolsUtils.js
@@ -4,18 +4,16 @@
 
 "use strict";
 
 /**
  * General utilities used throughout devtools that can also be used in
  * workers.
  */
 
-var flags = require("./flags");
-
 /**
  * Immutably reduce the given `...objs` into one object. The reduction is
  * applied from left to right, so `immutableUpdate({ a: 1 }, { a: 2 })` will
  * result in `{ a: 2 }`. The resulting object is frozen.
  *
  * Example usage:
  *
  *     const original = { foo: 1, bar: 2, baz: 3 };
@@ -109,19 +107,17 @@ exports.makeInfallible = function(handle
   return function() {
     try {
       return handler.apply(this, arguments);
     } catch (ex) {
       let who = "Handler function";
       if (name) {
         who += " " + name;
       }
-      if (!flags.quiet) {
-        exports.reportException(who, ex);
-      }
+      exports.reportException(who, ex);
       return undefined;
     }
   };
 };
 
 /**
  * Turn the |error| into a string, without fail.
  *
--- a/devtools/shared/flags.js
+++ b/devtools/shared/flags.js
@@ -53,20 +53,13 @@ makePrefTrackedFlag(exports, "wantLoggin
 /**
  * Setting the "devtools.debugger.log.verbose" preference to true will enable a
  * more verbose logging of the the RDP. The "devtools.debugger.log" preference
  * must be set to true as well for this to have any effect.
  */
 makePrefTrackedFlag(exports, "wantVerbose", "devtools.debugger.log.verbose");
 
 /**
- * Setting the "devtools.debugger.quiet" preference to true will turn off
- * logging for protocol errors that were caught and handled. These errors can
- * happen in normal operation when threads shut down.
- */
-makePrefTrackedFlag(exports, "quiet", "devtools.debugger.quiet");
-
-/**
  * Setting the "devtools.testing" preference to true will toggle on certain
  * behaviors that can differ from the production version of the code. These
  * behaviors typically enable easier testing or enhanced debugging features.
  */
 makePrefTrackedFlag(exports, "testing", "devtools.testing");
--- a/devtools/shared/fronts/targets/target-mixin.js
+++ b/devtools/shared/fronts/targets/target-mixin.js
@@ -7,18 +7,16 @@
 // We are requiring a module from client whereas this module is from shared.
 // This shouldn't happen, but Fronts should rather be part of client anyway.
 // Otherwise gDevTools is only used for local tabs and should propably only
 // used by a subclass, specific to local tabs.
 loader.lazyRequireGetter(this, "gDevTools", "devtools/client/framework/devtools", true);
 loader.lazyRequireGetter(this, "TargetFactory", "devtools/client/framework/target", true);
 loader.lazyRequireGetter(this, "getFront", "devtools/shared/protocol", true);
 
-const flags = require("../../flags");
-
 /**
  * A Target represents a debuggable context. It can be a browser tab, a tab on
  * a remote device, like a tab on Firefox for Android. But it can also be an add-on,
  * as well as firefox parent process, or just one of its content process.
  * A Target is related to a given TargetActor, for which we derive this class.
  *
  * Providing a generalized abstraction of a web-page or web-browser (available
  * either locally or remotely) is beyond the scope of this class (and maybe
@@ -548,29 +546,25 @@ function TargetMixin(parentClass) {
         } else if (this.detach && this.actorID) {
           // The client was handed to us, so we are not responsible for closing
           // it. We just need to detach from the tab, if already attached.
           // |detach| may fail if the connection is already dead, so proceed with
           // cleanup directly after this.
           try {
             await this.detach();
           } catch (e) {
-            if (!flags.quiet) {
-              console.warn(`Error while detaching target: ${e.message}`);
-            }
+            console.warn(`Error while detaching target: ${e.message}`);
           }
         }
 
         if (this.threadClient) {
           try {
             await this.threadClient.detach();
           } catch (e) {
-            if (!flags.quiet) {
-              console.warn(`Error while detaching the thread front: ${e.message}`);
-            }
+            console.warn(`Error while detaching the thread front: ${e.message}`);
           }
         }
 
         // Do that very last in order to let a chance to dispatch `detach` requests.
         super.destroy();
 
         this._cleanup();
       })();
--- a/devtools/shared/preferences/devtools-shared.js
+++ b/devtools/shared/preferences/devtools-shared.js
@@ -27,17 +27,16 @@ pref("devtools.debugger.remote-enabled",
 // In local builds, enable the browser toolbox by default
 pref("devtools.chrome.enabled", true, sticky);
 pref("devtools.debugger.remote-enabled", true, sticky);
 #endif
 
 // Disable remote debugging protocol logging
 pref("devtools.debugger.log", false);
 pref("devtools.debugger.log.verbose", false);
-pref("devtools.debugger.quiet", false);
 
 pref("devtools.debugger.remote-port", 6000);
 pref("devtools.debugger.remote-websocket", false);
 // Force debugger server binding on the loopback interface
 pref("devtools.debugger.force-local", true);
 
 // Limit for intercepted request and response bodies (1 MB)
 // Possible values: