lighthouse npm有时会导致互动时间和页面速度评分失败

lighthouse npm有时会导致互动时间和页面速度评分失败,npm,puppeteer,pagespeed,lighthouse,pagespeed-insights,Npm,Puppeteer,Pagespeed,Lighthouse,Pagespeed Insights,我正在使用lighthouse npm测试一些随机URL。。。有时离开会失败 ['audits']['interactive']['rawValue'] 及 空的 配置中是否有避免这种情况的方法,或者“重试直到不再失败”是我最好的更改 这是我的设置。它是木偶演员+灯塔 Start Puppeteer + open URL const browser = await puppeteer.launch({ args: ['--no-sandbox'] }); const p

我正在使用lighthouse npm测试一些随机URL。。。有时离开会失败

['audits']['interactive']['rawValue']

空的

配置中是否有避免这种情况的方法,或者“重试直到不再失败”是我最好的更改

这是我的设置。它是木偶演员+灯塔

    Start Puppeteer + open URL
    const browser = await puppeteer.launch({ args: ['--no-sandbox'] });
    const page = await browser.newPage()
    await page.goto(urlToTest, {
        waitUntil: 'networkidle2',
        timeout: 0
    });

    //Start Lighthouse 
    let opts = {
        chromeFlags: ['--show-paint-rects'],
        output: 'html',
        throttlingMethod: 'provided',
        throttling: {   
            throughputKbps: 8000,
            downloadThroughputKbps: 8000,
            uploadThroughputKbps: 2000
        }
    };

    opts.port = (new URL(browser.wsEndpoint())).port;
    let lighthouseResults = await lighthouse(urlToTest, opts, config = null);
    Start Puppeteer + open URL
    const browser = await puppeteer.launch({ args: ['--no-sandbox'] });
    const page = await browser.newPage()
    await page.goto(urlToTest, {
        waitUntil: 'networkidle2',
        timeout: 0
    });

    //Start Lighthouse 
    let opts = {
        chromeFlags: ['--show-paint-rects'],
        output: 'html',
        throttlingMethod: 'provided',
        throttling: {   
            throughputKbps: 8000,
            downloadThroughputKbps: 8000,
            uploadThroughputKbps: 2000
        }
    };

    opts.port = (new URL(browser.wsEndpoint())).port;
    let lighthouseResults = await lighthouse(urlToTest, opts, config = null);