Skip to content

Commit

Permalink
core(driver): warn about remaining inflight requests urls
Browse files Browse the repository at this point in the history
  • Loading branch information
doteric committed Apr 19, 2023
1 parent 2b8caf2 commit ebb6cc3
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions core/gather/driver/wait-for-condition.js
Original file line number Diff line number Diff line change
Expand Up @@ -487,6 +487,18 @@ async function waitForFullyLoaded(session, networkMonitor, options) {
throw new LighthouseError(LighthouseError.errors.PAGE_HUNG);
}

// Log remaining inflight requests if any.
const inflightRequestUrls = networkMonitor
.getInflightRequests()
.map((request) => request.url);
if (inflightRequestUrls.length > 0) {
log.warn(
'waitFor',
'Remaining inflight requests URLs',
inflightRequestUrls
);
}

return {timedOut: true};
};
});
Expand Down

0 comments on commit ebb6cc3

Please sign in to comment.