Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

eviscerate runLighthouse #1

Merged
merged 1 commit into from
Nov 22, 2019

Conversation

paulirish
Copy link

@paulirish paulirish commented Nov 21, 2019

@brendankenny this yeah?

it's accompanied with these devtools changes:

diff --git a/front_end/audits_worker/AuditsService.js b/front_end/audits_worker/AuditsService.js
index a66191cb..f8d6bc80 100644
--- a/front_end/audits_worker/AuditsService.js
+++ b/front_end/audits_worker/AuditsService.js
@@ -51,8 +51,19 @@ var AuditsService = class {  // eslint-disable-line
       this.statusUpdate(message[1]);
     });
 
+
     return Promise.resolve()
-        .then(_ => self.runLighthouseInWorker(this, params.url, params.flags, params.categoryIDs))
+        .then(_ => {
+          const flags = params.flags;
+          flags.logLevel=flags.logLevel||'info';
+          flags.channel='devtools';
+
+          const connection = self.setUpWorkerConnection(this);
+          const config = getDefaultConfigForCategories(params.categoryIDs);
+          const url = params.url;
+
+          return self.runLighthouse(url, flags, config, connection)
+        })
         .then(/** @type {!ReportRenderer.RunnerResult} */ result => {
           // Keep all artifacts on the result, no trimming
           return result;
@@ -126,6 +137,8 @@ var AuditsService = class {  // eslint-disable-line
 
 // Make lighthouse and traceviewer happy.
 global = self;
+global.devtools=true;
+
 global.isVinn = true;
 global.document = {};
 global.document.documentElement = {};

@brendankenny
Copy link

Yep, LGTM!

+global.devtools=true

except where did that sneak in from :)

@paulirish
Copy link
Author

+global.devtools=true

except where did that sneak in from :)

from the dt-5-7 branch.

ill cherrypick @chruxin's PR into that branch and roll that to devtools.

@paulirish
Copy link
Author

@chruxin can you merge this? it'll bring my commit into your existing PR.

@chruxin chruxin merged commit 89d10eb into chruxin:split-up-dt Nov 22, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants