NetworkError: failed to connect to WebSocket: Invalid status code
Closed this issue · 3 comments
pting-me commented
System: Intel macOS 12.6.5
Chrome downloaded via:
PUPPETEER_PRODUCT=chrome deno run -A --unstable https://deno.land/x/puppeteer@16.2.0/install.ts
Simple script:
import puppeteer from 'https:/deno.land/x/puppeteer@16.2.0/mod.ts';
const browser = await puppeteer.launch({
defaultViewport: { width: 1200, height: 675 },
});
Full error dump:
ErrorEvent {
bubbles: false,
cancelable: false,
composed: false,
currentTarget: null,
defaultPrevented: false,
eventPhase: 0,
srcElement: null,
target: WebSocket {
url: "ws://127.0.0.1:58347/devtools/browser/b767004f-f789-426e-a294-256b9b49c1ed",
readyState: 3,
extensions: "",
protocol: "",
binaryType: "blob",
bufferedAmount: 0
},
returnValue: true,
timeStamp: 1683480676254,
type: "error",
message: "NetworkError: failed to connect to WebSocket: Invalid status code",
filename: "",
lineno: 0,
colno: 0,
error: DOMException: failed to connect to WebSocket: Invalid status code
}
EvinceMoi commented
Got the same issue, the only thing I know for now is that there is some breaking changes in Deno 1.33. as I downgraded to 1.32.5, there was no problem, you can try it
pting-me commented
Awesome! That seems to work, thanks! I guess I'll leave this open until it's officially resolved in Deno.
pting-me commented
Actually, upgraded to 1.33.2 and seems to be working now. Closing.