-
Notifications
You must be signed in to change notification settings - Fork 9.6k
Open
Description
Lighthouse ignores wait time thresholds that are lower than the nonSimulatedSettingsOverrides if the throttling method is not set to simulate.
lighthouse/core/config/config.js
Line 192 in 6ca156b
| * Overrides the quiet windows when throttlingMethod requires observation. |
/**
* Overrides the quiet windows when throttlingMethod requires observation.
*
* @param {LH.Config.Settings} settings
*/
function overrideThrottlingWindows(settings) {
if (settings.throttlingMethod === 'simulate') return;
settings.cpuQuietThresholdMs = Math.max(
settings.cpuQuietThresholdMs || 0,
nonSimulatedSettingsOverrides.cpuQuietThresholdMs
);
settings.networkQuietThresholdMs = Math.max(
settings.networkQuietThresholdMs || 0,
nonSimulatedSettingsOverrides.networkQuietThresholdMs
);
settings.pauseAfterFcpMs = Math.max(
settings.pauseAfterFcpMs || 0,
nonSimulatedSettingsOverrides.pauseAfterFcpMs
);
settings.pauseAfterLoadMs = Math.max(
settings.pauseAfterLoadMs || 0,
nonSimulatedSettingsOverrides.pauseAfterLoadMs
);
}
It seems unintuitive that these values are ignored when the user is passing them in through the config, and I've been caught by this several times.
Maybe it's not necessary?
Metadata
Metadata
Assignees
Labels
No labels