-
Notifications
You must be signed in to change notification settings - Fork 55
Closed as not planned
Labels
bugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomerswontfixThis will not be worked onThis will not be worked on
Description
System info
- Playwright Version: 1.49.1
- Operating System: All
- Browser: Chrome
Source code
const { chromium } = require('patchright');
(async () => {
const browser = await chromium.launch({
headless: false,
viewport: null,
channel: 'chrome',
});
const context = await browser.newContext();
const page = await context.newPage();
await page.routeWebSocket(() => true, ws => {
const server = ws.connectToServer();
ws.onMessage(message => {
console.log('sent',message);
server.send(message);
});
server.onMessage(message => {
console.log('received',message);
ws.send(message);
});
});
await page.goto('https://www.olybet.ee/sports/live');
})();
- I provided exact source code that allows reproducing the issue locally.
Steps
- Run the provided Script
Expected
Logs all the messages from WebSocket connections on the current page.
Actual
Nothing is logged. If you try with the regular Playwright it works properly.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomerswontfixThis will not be worked onThis will not be worked on