playwright/packages
Yury Semikhatsky 7a72adc33c
cherry-pick(#29180): fix: interception id not found error in route.co… (#29222)
…ntinue

We stopped catching all exceptions in
https://github.com/microsoft/playwright/pull/28539 in hope that we'll
get loadingFailed even before Fetch.continue/fulfill command's error.
Turns out this is racy and may fail if the test cancels the request
while we are continuing it. The following test could in theory reproduce
it if stars align and the timing is good:

```js
it('page.continue on canceled request', async ({ page }) => {
  let resolveRoute;
  const routePromise = new Promise<Route>(f => resolveRoute = f);
  await page.route('http://test.com/x', resolveRoute);

  const evalPromise = page.evaluate(async () => {
    const abortController = new AbortController();
    (window as any).abortController = abortController;
    return fetch('http://test.com/x', { signal: abortController.signal }).catch(e => 'cancelled');
  });
  const route = await routePromise;
  void page.evaluate(() => (window as any).abortController.abort());
  await new Promise(f => setTimeout(f, 10));
  await route.continue();
  const req = await evalPromise;
  expect(req).toBe('cancelled');
});
```

Fixes https://github.com/microsoft/playwright/issues/29123
2024-01-29 09:33:09 -08:00
..
html-reporter chore: reuse image diff component in trace/html (#28727) 2023-12-22 10:17:35 -08:00
playwright chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-browser-chromium chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-browser-firefox chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-browser-webkit chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-chromium chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-core cherry-pick(#29180): fix: interception id not found error in route.co… (#29222) 2024-01-29 09:33:09 -08:00
playwright-ct-core chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-ct-react chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-ct-react17 chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-ct-solid chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-ct-svelte chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-ct-vue chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-ct-vue2 chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-firefox chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-test chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
playwright-webkit chore: mark 1.41.1 (#29075) 2024-01-20 00:05:04 +01:00
protocol/src feat(vrt): allow providing screenshot style (#28229) 2023-11-30 17:42:45 -08:00
recorder chore: make asLocator() always safe (#28207) 2023-11-16 16:31:34 -08:00
trace/src feat(trace): show target point for raw mouse apis (#28459) 2023-12-07 06:27:49 -08:00
trace-viewer Revert "feat(trace): allow Trace Viewer to include credentials when fetching traces cross-origin (#28502)" (#29024) 2024-01-17 10:41:44 -08:00
web cherry-pick(#28986): fix(ct): move import list into the compilation cache data 2024-01-18 11:42:56 -08:00
.eslintrc-with-ts-config.js lint: prevent object string concatenation (#23172) 2023-05-19 15:17:43 -07:00
.eslintrc.js chore: replace process.exit with graceful closure (#24242) 2023-07-24 08:29:29 -07:00