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

[tips] Workaround when gulp gets stuck #340

Open
t2ym opened this issue Feb 21, 2020 · 0 comments
Open

[tips] Workaround when gulp gets stuck #340

t2ym opened this issue Feb 21, 2020 · 0 comments

Comments

@t2ym
Copy link
Owner

t2ym commented Feb 21, 2020

[tips] Workaround when gulp gets stuck

Root Cause

  • There may be some race conditions in gulp demo process

Workaround

  • Disable headless mode of Chrome
diff --git a/demo-backend/cacheBundleGeneration.js b/demo-backend/cacheBundleGeneration.js
index 6a829b2b..8c33ebfd 100644
--- a/demo-backend/cacheBundleGeneration.js
+++ b/demo-backend/cacheBundleGeneration.js
@@ -61,8 +61,8 @@ const loadOnly = process.argv[2] === 'loadOnly';
   console.log('serverSecret', serverSecret);
   await new Promise(resolve => setTimeout(resolve, 4000));
   console.log('wait 4000');
-  let browser = await puppeteer.launch({ headless: true, dumpio: false, args: ['--disable-gpu', '--no-sandbox', '--no-setsuid-sandbox'], executablePath: chromePath }); // terse and fastest
-  //let browser = await puppeteer.launch({ headless: false, dumpio: true, args: [ '--disable-gpu', '--enable-logging=stderr' ], executablePath: chromePath });
+  //let browser = await puppeteer.launch({ headless: true, dumpio: false, args: ['--disable-gpu', '--no-sandbox', '--no-setsuid-sandbox'], executablePath: chromePath }); // terse and fastest
+  let browser = await puppeteer.launch({ headless: false, dumpio: true, args: [ '--disable-gpu', '--enable-logging=stderr' ], executablePath: chromePath });
   //let browser = await puppeteer.launch({ headless: false, dumpio: true, args: [ '--disable-gpu', '--enable-logging=stderr', '--auto-open-devtools-for-tabs' ], executablePath: chromePath });
   let page = await browser.newPage();
   await page.setViewport({ width: 1200, height: 800 });
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant