Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show message when service workers are blocked #997

Closed
frank-dspeed opened this issue Sep 18, 2019 · 6 comments
Closed

Show message when service workers are blocked #997

frank-dspeed opened this issue Sep 18, 2019 · 6 comments
Assignees
Labels
bug Something isn't working

Comments

@frank-dspeed
Copy link

  • code-server version:v2
  • OS Version: docker image

Description

console output on extension install

Service Workers are not enabled. Webviews will not work properly
Blocked script execution in 'http://0.0.0.0:8080/webview/fake.html?id=extensionEditor' because the document's frame is sandboxed and the 'allow-scripts' permission is not set.

Steps to Reproduce

open code-server install remote workspace extension

@frank-dspeed frank-dspeed added the bug Something isn't working label Sep 18, 2019
@sr229
Copy link
Contributor

sr229 commented Sep 18, 2019

@code-asher I'm sure we did have service workers enabled for some builds but we have them disabled by default somehow, hence this error.

@code-asher
Copy link
Member

Unfortunately service workers will only work over secure origins (localhost/127.0.0.1 or https). You'll need to browse using something other than http://0.0.0.0. 😢

@code-asher
Copy link
Member

Re-opening though because we should have some sort of message explaining what's going on to the user. Also, while some of the webview stuff won't work you should still at least be able to see an extension's data. Are you just trying to view an extension's README or something?

@code-asher code-asher reopened this Sep 18, 2019
@frank-dspeed
Copy link
Author

@code-asher yes i can see the general data like the readme all is working it only hangs on install but then finishes correctly. i will try the https suggestion and i think we should stop then supporting running under http as it makes no sense to run a product in a inconsistent state.

@frank-dspeed
Copy link
Author

i think this needs to be documented directly in the readme with high priority

@sr229
Copy link
Contributor

sr229 commented Sep 19, 2019

i think this needs to be documented directly in the readme with high priority

I say we hold it for now. I'm opening a line of dialogue within the Chromium developers regarding reserved internal IP CIDRs for service workers and clipboard API.

@code-asher yes i can see the general data like the readme all is working it only hangs on install but then finishes correctly. i will try the https suggestion and i think we should stop then supporting running under http as it makes no sense to run a product in a inconsistent state.

Forcing HTTP/S is not exactly a good state either - this is where some of the complexity Kubernetes had as well because of its strict requirement for HTTP/S (which is understandable).

Again, refer to my response - I'm still opening a line of dialogue with the Chromium team regarding to consider allowing internal CIDRs to use HTTP/S-restricted features.

@nhooyr nhooyr removed the v2 label Jan 27, 2020
@nhooyr nhooyr changed the title [v2] Bug Webviews do not work Show message when service workers are blocked Feb 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants