code-server: New 3.9.2 not work on iPadOS, Safari
OS/Web Information
- Web Browser: iPad Safari
- Local OS: iPadOS 14.4.1
- Remote OS: Ubuntu Debian GNU/Linux 9.13 (stretch)
- Remote Architecture: amd64
code-server --version: 3.9.2 109d2ce3247869eaeab67aa7e5423503ec9eb859
Steps to Reproduce
- Open safari, navigate to server url
Expected
- Show UI after login
Actual
- Just blank after login
Screenshot
Notes
Seems cause by permessage-deflate extension, maybe add a option via command line is better?
[Log] [Service Worker] registered (register.js, line 14)
[Error] WebSocket connection to 'wss://ide.dosk.win/?reconnectionToken=4ab75c9c-1248-4a08-80ec-491ff6d51b5e&reconnection=false&skipWebSocketFrames=false' failed: Received unexpected extension: permessage-deflate
[Log] ERR – "[remote-connection][Management ][4ab75…][initial][ide.dosk.win:80] socketFactory.connect() failed or timed out. Error:" (workbench.web.api.js, line 626)
[Log] ERR (workbench.web.api.js, line 626)
Error: WebSocket close with status code 1006
[Log] ERR – "[remote-connection] An error occurred in the very first connect attempt, it will be treated as a permanent error! Error:" (workbench.web.api.js, line 626)
[Log] ERR – Error: WebSocket close with status code 1006 (workbench.web.api.js, line 626)
Error: WebSocket close with status code 1006
[Log] ERR – Error: WebSocket close with status code 1006 (workbench.web.api.js, line 626)
Error: WebSocket close with status code 1006
[Log] WARN – "Ignoring the error while validating workspace folder vscode-remote://ide.dosk.win/data00/home/chenfuchun/Public/Codes/native/aha …" (workbench.web.api.js, line 626)
"Ignoring the error while validating workspace folder vscode-remote://ide.dosk.win/data00/home/chenfuchun/Public/Codes/native/aha - WebSocket close with status code 1006"
[Warning] The web worker extension host is started without an iframe sandbox! (workbench.web.api.js, line 1713)
[Log] ERR – "WebSocket close with status code 1006: M@https://ide.dosk.win/static/109d2ce3247869eaeab67aa7e5423503ec9eb859/usr/lib/code-server/lib/vscode…" (workbench.web.api.js, line 626)
"WebSocket close with status code 1006: M@https://ide.dosk.win/static/109d2ce3247869eaeab67aa7e5423503ec9eb859/usr/lib/code-server/lib/vscode/out/vs/workbench/workbench.web.api.js:631:2095297
https://ide.dosk.win/static/109d2ce3247869eaeab67aa7e5423503ec9eb859/usr/lib/code-server/lib/vscode/out/vs/workbench/workbench.web.api.js:631:2097056"
[Log] ERR (1) (workbench.web.api.js, line 626)
JSON Parse error: Unexpected identifier "undefined": parsegetCachedViewContainerLocations — workbench.web.api.js:2743:8418733Zt — workbench.web.api.js:2743:8410218_createInstance — workbench.web.api.js:622:1893008_createAndCacheServiceInstance — workbench.web.api.js:622:1894626_safeCreateAndCacheServiceInstance — workbench.web.api.js:622:1893823get — workbench.web.api.js:622:1892109initLayout — workbench.web.api.js:2408:7646399(anonymous function) — workbench.web.api.js:2408:7692599asyncFunctionResumeinvokeFunction — workbench.web.api.js:622:1891952startup — workbench.web.api.js:2408:7692454(anonymous function) — workbench.web.api.js:2408:7698254asyncFunctionResume[native code]promiseReactionJobWithoutPromisepromiseReactionJob
[Log] ERR – "WebSocket close with status code 1006: M@https://ide.dosk.win/static/109d2ce3247869eaeab67aa7e5423503ec9eb859/usr/lib/code-server/lib/vscode…" (workbench.web.api.js, line 626)
"WebSocket close with status code 1006: M@https://ide.dosk.win/static/109d2ce3247869eaeab67aa7e5423503ec9eb859/usr/lib/code-server/lib/vscode/out/vs/workbench/workbench.web.api.js:631:2095297
https://ide.dosk.win/static/109d2ce3247869eaeab67aa7e5423503ec9eb859/usr/lib/code-server/lib/vscode/out/vs/workbench/workbench.web.api.js:631:2097056"
[Log] ERR (1) (workbench.web.api.js, line 626)
JSON Parse error: Unexpected identifier "undefined": parsegetCachedViewContainerLocations — workbench.web.api.js:2743:8418733Zt — workbench.web.api.js:2743:8410218_createInstance — workbench.web.api.js:622:1893008_createAndCacheServiceInstance — workbench.web.api.js:622:1894626_safeCreateAndCacheServiceInstance — workbench.web.api.js:622:1893823get — workbench.web.api.js:622:1892109(anonymous function) — workbench.web.api.js:2408:7698537invokeFunction — workbench.web.api.js:622:1891952asyncFunctionResume[native code]promiseReactionJobWithoutPromise
[Log] ERR – "WebSocket close with status code 1006: M@https://ide.dosk.win/static/109d2ce3247869eaeab67aa7e5423503ec9eb859/usr/lib/code-server/lib/vscode…" (workbench.web.api.js, line 626)
"WebSocket close with status code 1006: M@https://ide.dosk.win/static/109d2ce3247869eaeab67aa7e5423503ec9eb859/usr/lib/code-server/lib/vscode/out/vs/workbench/workbench.web.api.js:631:2095297
https://ide.dosk.win/static/109d2ce3247869eaeab67aa7e5423503ec9eb859/usr/lib/code-server/lib/vscode/out/vs/workbench/workbench.web.api.js:631:2097056"
This issue can be reproduced in VS Code:No
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 35 (20 by maintainers)
Update:
Oh no! Thank you @springhack for the detailed report and the patches.
And thank you @sh1luo for your extra notes as well!
We’ll see what we can do to fix this (and prevent it from happening again). cc @code-asher
Thank You , I had the same issue. code server v3.9.2 ipad prt 12.9 4thg os 14.4.2 safari & chrome It works for me now
Hello,
I know issue is closed but issues #3004 #3017 and #3014 are related with this one.
Basically regardless of middlewares (proxy, ingress, etc…) when user opens up code-server in browser, and if browser doesn’t properly support websocket zlib compression and/or negotiation it fails. (Websocket Error 1006 in Safari)
Just my 2 cents about what you guys can do about it:
@jsjoeio I can confirm this happens in Safari on macOS 11.
The root of the error seems to be:
Anybody else confirm? Running
Chrome 89.0.4389.90Edit: Also broken with the same error in
Firefox 87.0using chrome on ipadOS gets the same error,just blank. But everything goes well on Android OS.
Version 3.9.3 work for me, iPadOS 14.4.2, install using deb package
I can confirm v3.9.3 works for me: IpadOS 14.4.2, microk8s v1.20.5, helm chart, Safari
Edit 1: Chrome JS Console on iPad shows following:
Edit 2: I did some more investigation with Safari. Other than 404 messages as in #1640, only major diference is:
I think it’s easier for me to just update iOS to latest version.
@nodesocket
Instead of recreating the pod; try restarting the s6 service after applying the patch and while still in the pod. I also assumed you did a ‘find’ on vscode.js, as the path was different to that of the patch on kubernetes in my case.
Worked for me.
I also would like to leave a comment. That “sed” fix looks like to be fixing the issue for iOS 14+, but apparently not for iOS 13.
On my iPhone with iOS 14.4.2 - fix worked. On my iPad with iOS 13.6.1 - after login still white page.
Re-deployed the pod, but still the same error.
@jsjoeio I got a Bash shell into the Kubernetes pod running
code-server:You want me to just try running:
@jsjoeio was this only related to Safari? Because, I am seeing this running
3.9.2.in Kubernetes via the Docker container and using both Chrome and Firefox.thank you.Using your method, after editing this file everything goes well on iOS.
Just upgraded to
3.9.2running in Kubernetes via Helm on Chrome and seeing this.