Backed out 3 changesets (bug 1685061, bug 1668218) for dt failures on browser_aboutdebugging_devtoolstoolbox_reload.js . CLOSED TREE
authorNarcis Beleuzu <nbeleuzu@mozilla.com>
Wed, 10 Feb 2021 19:40:43 +0200
changeset 566848 7d089aec8ffc916de4961193bf33c67f4a36aebf
parent 566847 2badb161c9cae0d54ce26fd558567ffcb2fb638f
child 566849 93184b7fe095d0e77615e70a9c7e96592b5fb293
push id38191
push userbtara@mozilla.com
push dateThu, 11 Feb 2021 05:02:45 +0000
treeherdermozilla-central@5cbcb80f72bd [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1685061, 1668218
milestone87.0a1
backs out734d6233d1cdab2a6d50d1385de64bc5207a542f
7dcb92850f2201721f997658ef72ee51bf513909
2443341cb2526439e5708b7d8443f714115602b0
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 3 changesets (bug 1685061, bug 1668218) for dt failures on browser_aboutdebugging_devtoolstoolbox_reload.js . CLOSED TREE Backed out changeset 734d6233d1cd (bug 1685061) Backed out changeset 7dcb92850f22 (bug 1668218) Backed out changeset 2443341cb252 (bug 1685061)
browser/app/profile/firefox.js
devtools/client/definitions.js
devtools/client/locales/en-US/perftools.ftl
devtools/client/locales/en-US/toolbox-options.ftl
devtools/client/performance-new/components/OnboardingMessage.js
devtools/client/performance-new/initializer.js
devtools/client/performance/test/head.js
devtools/client/performance/test/helpers/prefs.js
--- a/browser/app/profile/firefox.js
+++ b/browser/app/profile/firefox.js
@@ -2401,22 +2401,18 @@ pref("devtools.browserconsole.input.edit
 
 // Editor width for webconsole and browserconsole.
 pref("devtools.webconsole.input.editorWidth", 0);
 pref("devtools.browserconsole.input.editorWidth", 0);
 
 // Display an onboarding UI for the Editor mode.
 pref("devtools.webconsole.input.editorOnboarding", true);
 
-// Enable the new performance recording panel in Nightly builds.
-#if defined(NIGHTLY_BUILD)
-  pref("devtools.performance.new-panel-enabled", true);
-#else
-  pref("devtools.performance.new-panel-enabled", false);
-#endif
+// Disable the new performance recording panel by default
+pref("devtools.performance.new-panel-enabled", false);
 
 // Enable message grouping in the console, true by default
 pref("devtools.webconsole.groupWarningMessages", true);
 
 // Saved state of the Display content messages checkbox in the browser console.
 pref("devtools.browserconsole.contentMessages", false);
 
 // Enable client-side mapping service for source maps
--- a/devtools/client/definitions.js
+++ b/devtools/client/definitions.js
@@ -273,21 +273,22 @@ function switchPerformancePanel() {
     Services.prefs.getBoolPref("devtools.performance.new-panel-enabled", false)
   ) {
     Tools.performance.url =
       "chrome://devtools/content/performance-new/index.xhtml";
     Tools.performance.build = function(frame, target) {
       return new NewPerformancePanel(frame, target);
     };
     Tools.performance.isTargetSupported = function(target) {
-      // Only use the new performance panel on local tab toolboxes, as they are guaranteed
-      // to have a performance actor.
-      // Remote tab toolboxes (eg about:devtools-toolbox from about:debugging) should not
-      // use the performance panel; about:debugging provides a "Profile performance" button
-      // which can be used instead, without having the overhead of starting a remote toolbox.
+      // Root actors are lazily initialized, so we can't check if the target has
+      // the perf actor yet. Also this function is not async, so we can't initialize
+      // the actor yet.
+      // We don't display the new performance panel for remote context in the
+      // toolbox, because this has an overhead. Instead we should use
+      // about:debugging.
       return target.isLocalTab;
     };
   } else {
     Tools.performance.url = "chrome://devtools/content/performance/index.xhtml";
     Tools.performance.build = function(frame, target) {
       return new PerformancePanel(frame, target);
     };
     Tools.performance.isTargetSupported = function(target) {
--- a/devtools/client/locales/en-US/perftools.ftl
+++ b/devtools/client/locales/en-US/perftools.ftl
@@ -101,22 +101,8 @@ perftools-thread-js-helper =
 
 ##
 
 perftools-record-all-registered-threads =
   Bypass selections above and record all registered threads
 
 perftools-tools-threads-input-label =
   .title = These thread names are a comma separated list that is used to enable profiling of the threads in the profiler. The name needs to be only a partial match of the thread name to be included. It is whitespace sensitive.
-
-## Onboarding UI labels. These labels are displayed in the new performance panel UI, when
-## both devtools.performance.new-panel-onboarding & devtools.performance.new-panel-enabled
-## preferences are true.
-
--profiler-brand-name = Firefox Profiler
-
-perftools-onboarding-message = <b>New</b>: { -profiler-brand-name } is now integrated into Developer Tools. <a>Learn more</a> about this powerful new tool.
-
-# `options-context-advanced-settings` is defined in toolbox-options.ftl
-perftools-onboarding-reenable-old-panel = (For a limited time, you can access the original Performance panel via <a>{ options-context-advanced-settings }</a>)
-
-perftools-onboarding-close-button =
-  .aria-label = Close the onboarding message
--- a/devtools/client/locales/en-US/toolbox-options.ftl
+++ b/devtools/client/locales/en-US/toolbox-options.ftl
@@ -88,17 +88,17 @@ options-sourceeditor-expandtab-tooltip =
     .title = Use spaces instead of the tab character
 options-sourceeditor-expandtab-label = Indent using spaces
 options-sourceeditor-tabsize-label = Tab size
 options-sourceeditor-keybinding-label = Keybindings
 options-sourceeditor-keybinding-default-label = Default
 
 ## Advanced section
 
-# The heading (this item is also used in perftools.ftl)
+# The heading
 options-context-advanced-settings = Advanced settings
 
 # The label for the checkbox that toggles the HTTP cache on or off
 options-disable-http-cache-label = Disable HTTP Cache (when toolbox is open)
 options-disable-http-cache-tooltip =
     .title = Turning this option on will disable the HTTP cache for all tabs that have the toolbox open. Service Workers are not affected by this option.
 
 # The label for checkbox that toggles JavaScript on or off
--- a/devtools/client/performance-new/components/OnboardingMessage.js
+++ b/devtools/client/performance-new/components/OnboardingMessage.js
@@ -13,29 +13,23 @@
  */
 
 /**
  * @typedef {import("../@types/perf").PanelWindow} PanelWindow
  */
 
 "use strict";
 
-const {
-  PureComponent,
-  createFactory,
-} = require("devtools/client/shared/vendor/react");
+const { PureComponent } = require("devtools/client/shared/vendor/react");
 const {
   b,
   button,
   div,
   p,
 } = require("devtools/client/shared/vendor/react-dom-factories");
-const Localized = createFactory(
-  require("devtools/client/shared/vendor/fluent-react").Localized
-);
 
 const Services = require("Services");
 const { openDocLink } = require("devtools/client/shared/link");
 
 const LEARN_MORE_URL =
   "https://developer.mozilla.org/docs/Mozilla/Performance/Profiling_with_the_Built-in_Profiler";
 const ONBOARDING_PREF = "devtools.performance.new-panel-onboarding";
 
@@ -96,56 +90,55 @@ class OnboardingMessage extends PureComp
   };
 
   render() {
     const { isOnboardingEnabled } = this.state;
     if (!isOnboardingEnabled) {
       return null;
     }
 
-    const learnMoreLink = button({
-      className: "perf-external-link",
-      onClick: this.handleLearnMoreClick,
-    });
-
-    const settingsLink = button({
-      className: "perf-external-link",
-      onClick: this.handleSettingsClick,
-    });
+    const learnMoreLink = button(
+      {
+        className: "perf-external-link",
+        onClick: this.handleLearnMoreClick,
+      },
+      "Learn more"
+    );
 
-    const closeButton = Localized(
+    const settingsLink = button(
       {
-        id: "perftools-onboarding-close-button",
-        attrs: { "aria-label": true },
+        className: "perf-external-link",
+        onClick: this.handleSettingsClick,
       },
-      button({
-        className:
-          "perf-onboarding-close-button perf-photon-button perf-photon-button-ghost",
-        onClick: this.handleCloseIconClick,
-      })
+      "Settings > Advanced"
     );
 
+    const closeButton = button({
+      "aria-label": "Close the onboarding message",
+      className:
+        "perf-onboarding-close-button perf-photon-button perf-photon-button-ghost",
+      onClick: this.handleCloseIconClick,
+    });
+
     return div(
       { className: "perf-onboarding" },
       div(
         { className: "perf-onboarding-message" },
-        Localized(
-          {
-            id: "perftools-onboarding-message",
-            b: b(),
-            a: learnMoreLink,
-          },
-          p({ className: "perf-onboarding-message-row" })
+        p(
+          { className: "perf-onboarding-message-row" },
+          b({}, "New"),
+          ": Firefox Profiler is now integrated into Developer Tools. ",
+          learnMoreLink,
+          " about this powerful new tool."
         ),
-        Localized(
-          {
-            id: "perftools-onboarding-reenable-old-panel",
-            a: settingsLink,
-          },
-          p({ className: "perf-onboarding-message-row" })
+        p(
+          { className: "perf-onboarding-message-row" },
+          "(For a limited time, you can access the original Performance panel via ",
+          settingsLink,
+          ")"
         )
       ),
       closeButton
     );
   }
 }
 
 module.exports = OnboardingMessage;
--- a/devtools/client/performance-new/initializer.js
+++ b/devtools/client/performance-new/initializer.js
@@ -102,21 +102,17 @@ async function gInit(perfFront, pageCont
     const panelWindow = /** @type {PanelWindow} */ (anyWindow);
     // The store variable is a `ReduxStore`, not our `Store` type, as defined
     // in perf.d.ts. Coerce it into the `Store` type.
     const anyStore = /** @type {any} */ (store);
     panelWindow.gStore = anyStore;
   }
 
   const l10n = new FluentL10n();
-  await l10n.init([
-    "devtools/client/perftools.ftl",
-    // Needed for the onboarding UI
-    "devtools/client/toolbox-options.ftl",
-  ]);
+  await l10n.init(["devtools/client/perftools.ftl"]);
 
   // Do some initialization, especially with privileged things that are part of the
   // the browser.
   store.dispatch(
     actions.initializeStore({
       perfFront,
       receiveProfile,
       recordingPreferences: getRecordingPreferences(
--- a/devtools/client/performance/test/head.js
+++ b/devtools/client/performance/test/head.js
@@ -91,19 +91,16 @@ const key = (id, win = window) => {
   // TODO: remove when we have flame charts via bug 1148663.
   Services.prefs.setBoolPref(PrefUtils.UI_ENABLE_MEMORY_FLAME_CHART, true);
 
   // By default, reduce the default buffer size to reduce the overhead when
   // transfering the profile data. Hopefully this should help to reduce our
   // intermittents for the performance tests.
   Services.prefs.setIntPref(PrefUtils.PROFILER_BUFFER_SIZE_PREF, 100000);
 
-  // Force the old panel
-  Services.prefs.setBoolPref("devtools.performance.new-panel-enabled", false);
-
   registerCleanupFunction(() => {
     info("finish() was called, cleaning up...");
 
     PrefUtils.rollbackPrefsToDefault();
     stopObservingPrefs();
 
     // Manually stop the profiler module at the end of all tests, to hopefully
     // avoid at least some leaks on OSX. Theoretically the module should never
--- a/devtools/client/performance/test/helpers/prefs.js
+++ b/devtools/client/performance/test/helpers/prefs.js
@@ -44,17 +44,16 @@ exports.DEFAULT_PREF_VALUES = [
   exports.UI_SHOW_PLATFORM_DATA_PREF,
   exports.UI_SHOW_IDLE_BLOCKS_PREF,
   exports.UI_ENABLE_FRAMERATE_PREF,
   exports.UI_ENABLE_MEMORY_PREF,
   exports.UI_ENABLE_ALLOCATIONS_PREF,
   exports.UI_ENABLE_MEMORY_FLAME_CHART,
   "devtools.performance.ui.show-jit-optimizations",
   "devtools.performance.ui.show-triggers-for-gc-types",
-  "devtools.performance.new-panel-enabled",
 ].reduce((prefValues, prefName) => {
   prefValues[prefName] = Preferences.get(prefName);
   return prefValues;
 }, {});
 
 /**
  * Invokes callback when a pref which is not in the `DEFAULT_PREF_VALUES` store
  * is changed. Returns a cleanup function.