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

[Bug]: Firefox not showing Jupyter file #5334

Closed
4 tasks done
Emporea opened this issue Jul 12, 2022 · 43 comments
Closed
4 tasks done

[Bug]: Firefox not showing Jupyter file #5334

Emporea opened this issue Jul 12, 2022 · 43 comments
Assignees
Milestone

Comments

@Emporea
Copy link

Emporea commented Jul 12, 2022

Is there an existing issue for this?

  • I have searched the existing issues

OS/Web Information

  • Web Browser: Firefox 102
  • Local OS: Win10
  • Remote OS: Ubuntu Focal
  • Remote Architecture: 86
  • code-server --version: 4.5.0 (About shows 4.4.0)

Steps to Reproduce

  1. Setup new docker instance
  2. Create test.ipynb file (doesnt matter if vscode-jupyter is installed or not)
  3. Open file with Firefox

Expected

Should show cells and Html Rendering

Actual

Endless Loading

Logs

Firefox Console (other browsers do not show this)


Uncaught (in promise) Error: Unable to write file 'vscode-log:/20220712T210007/window.log' (Error: IndexedDB database 'vscode-web-db' is closed.)
    h https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:9
    L https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:593
    writeFile https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:597
    _log https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:598
    consume https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:71
    queue https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:71
    queue https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:71
    _log https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:597
    error https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:597
    error https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:597
    _log https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:597
    error https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:597
    handleUnexpectedError https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:3072
    registerErrorHandler https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:3072
    onUnexpectedError https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:8
    R https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:8
    registerErrorHandler https://example.tld/stable-30d9c6cd9483b2cc586687151bcbcd635f373630/static/out/vs/workbench/workbench.web.main.js:3072
3 errors.ts:235
This page uses the non standard property “zoom”. Consider using calc() in the relevant property values, or using “transform” along with “transform-origin: 0 0”. example.tld
The web worker extension host is started in a same-origin iframe! webWorkerExtensionHost.ts:111:11
 INFO [Service Worker] registered log.ts:301:11
An iframe which has both allow-scripts and allow-same-origin for its sandbox attribute can remove its sandboxing. example.tld
The character encoding of a framed document was not declared. The document may appear different if viewed without the document framing it. webWorkerExtensionHostIframe.html
An iframe which has both allow-scripts and allow-same-origin for its sandbox attribute can remove its sandboxing. example.tld

Screenshot/Video

Firefox ( also tested with new installation / different machine / vm etc.):
Screenshot 2022-07-12 204315

Other Browsers I tested (Opera, Chrome, Vivaldi, in this screenshot Edge)
Screenshot 2022-07-12 204122

Does this issue happen in VS Code or GitHub Codespaces?

  • I cannot reproduce this in VS Code.
  • I cannot reproduce this in GitHub Codespaces.

Are you accessing code-server over HTTPS?

  • I am using HTTPS.

Notes

No response

@Emporea Emporea added bug Something isn't working triage This issue needs to be triaged by a maintainer labels Jul 12, 2022
@mathematicalmichael
Copy link

mathematicalmichael commented Jul 12, 2022

yeah this is happening with 4.5.0 but not 4.4.0 in Chrome, Safari, and Firefox. I just tried both side-by-side with fresh docker-based installs.
for what it's worth the 4.5.0 version also carries with it newer versions of the Jupyter extension. I tried downgrading to v2022.3.1000901801 with 4.5.0 but it didn't fix the problem. The Terminal also didn't work with 4.5.0.

@Emporea
Copy link
Author

Emporea commented Jul 12, 2022

Can confirm that this bug doesn't occur on 4.4.0

But I dont get how it can only affect one browser.

@jsjoeio
Copy link
Contributor

jsjoeio commented Jul 18, 2022

Is this a duplicate of #5335? Or are they somehow related?

@Emporea
Copy link
Author

Emporea commented Jul 18, 2022

@jsjoeio
I don't know how they are related (atleast they share downgrading to 4.4.0 as a workaround), but this is definitly not a duplicate.

@jsjoeio
Copy link
Contributor

jsjoeio commented Jul 18, 2022

Ah got it. Okay We'll investigate!

@mathematicalmichael
Copy link

mathematicalmichael commented Jul 20, 2022

@Emporea for me it is impacting all browsers I have installed.
@jsjoeio thank you very much for investigating! 4.4.0 is the first version where Jupyter notebooks actually function and it makes me so happy to finally be able to use code-server exclusively for my work.

@benz0li
Copy link
Contributor

benz0li commented Jul 20, 2022

Is this a duplicate of #5335?

No.

Or are they somehow related?

No, they are not.

@jsjoeio
Copy link
Contributor

jsjoeio commented Jul 20, 2022

@mathematicalmichael hooray! that's great to hear.

We really need to add some e2e tests for Jupyter. I'm going to add this to the next sprint.

@jsjoeio jsjoeio added needs-investigation This issue needs to be further investigated and removed bug Something isn't working triage This issue needs to be triaged by a maintainer labels Jul 20, 2022
@jsjoeio jsjoeio added this to the July 2022 milestone Jul 20, 2022
@benz0li
Copy link
Contributor

benz0li commented Jul 21, 2022

FYI code-server 4.5.1 is working fine with ms-toolsai.jupyter@2022.5.1001610507 and ms-python.python@2022.10.1.

@benz0li
Copy link
Contributor

benz0li commented Jul 21, 2022

@Emporea @mathematicalmichael Please test again with code-server 4.5.1.

Most probably related to #5321.

@jsjoeio
Copy link
Contributor

jsjoeio commented Jul 21, 2022

Hooray! Thank you @benz0li for testing and confirming!

@Emporea
Copy link
Author

Emporea commented Jul 21, 2022

Its working with 4.5.1. Thanks.

@Emporea
Copy link
Author

Emporea commented Jul 21, 2022

Wait. Its not. huh.. It opened one time, but had the same bug after that again.

@benz0li
Copy link
Contributor

benz0li commented Jul 21, 2022

@Emporea Use Firefox to log into https://demo.jupyter.b-data.ch.

If it does not work, it might be a problem with your Firefox settings or extensions.

@Emporea
Copy link
Author

Emporea commented Jul 21, 2022

I removed the docker container and recreated it and now its working so far. I hope it stays that way, cause i did that already several times, so it seems inconsistent for me. But thanks for solving it in theory.

@benz0li
Copy link
Contributor

benz0li commented Jul 21, 2022

But thanks for solving it in theory.

It runs just smoothly [also in practice] at https://demo.jupyter.b-data.ch 😉.

@Emporea
Copy link
Author

Emporea commented Jul 21, 2022

Sometimes its working. Sometimes not.
With 4.4.0 its working everytime.

@jsjoeio
Copy link
Contributor

jsjoeio commented Jul 21, 2022

Use Firefox to log into https://demo.jupyter.b-data.ch/.

@Emporea are you seeing the same results here?

@jsjoeio jsjoeio assigned jsjoeio and unassigned jsjoeio Jul 21, 2022
@Emporea
Copy link
Author

Emporea commented Jul 21, 2022

The demo is also not working.

@benz0li
Copy link
Contributor

benz0li commented Jul 21, 2022

The demo is also not working.

@Emporea It is a problem with your Firefox settings or extensions, then.

@Emporea
Copy link
Author

Emporea commented Jul 21, 2022

Whatever. The inconsistency makes it super hard to understand and to describe. You probably think i am a noob.
Well I stay on 4.4.0 for a while and see if the inconsistencies also occur there.

@benz0li
Copy link
Contributor

benz0li commented Jul 22, 2022

See also #4777 (comment) about private/incognito mode [and possibly opening a folder (File > Open Folder...) before opening a Jupyter notebook].

@jsjoeio
Copy link
Contributor

jsjoeio commented Jul 22, 2022

@Emporea not a noob! Just trying to help. Any other information you can share is helpful, otherwise I will try reproducing

mathematicalmichael added a commit to ml-starter-packs/microservice-workshop that referenced this issue Jul 22, 2022
@mathematicalmichael
Copy link

I have a containerized environment that launches in the cloud (free) via binder here: https://mybinder.org/v2/gh/ml-starter-packs/microservice-workshop/main?urlpath=vscode/ (Dockerfile).

latest commit pins codeserver to 4.5.1, and I found

  • terminal functioning as expected
  • notebooks working

@mathematicalmichael
Copy link

hm... unfortunately I got a weird error trying to even install extensions in the first place
image

don't know if it's related... but I tried 4.4.0 yesterday and it was fine. I'll try rolling back the commit and seeing if the behavior occurs again (is it MS-extensions related or code-server related?)

@jsjoeio
Copy link
Contributor

jsjoeio commented Jul 22, 2022

image

Weird, I'm seeing the same 🤔 open-vsx was down yesterday. maybe related?

Yeah, when i search for any extension i see the same error:

image

Looking at the network requests, it appears to be returning a 503

image

@mathematicalmichael
Copy link

oh okay, so not related to code-server?

sidenote: i love that you can reproduce the errors on your own thanks to binder... what an age we live in.

thank you so much for looking into it!

@jsjoeio
Copy link
Contributor

jsjoeio commented Jul 22, 2022

oh okay, so not related to code-server?

correct! @benz0li opened an issue upstream: eclipse/openvsx#497

sidenote: i love that you can reproduce the errors on your own thanks to binder... what an age we live in.

right?! crazy! though props to you for giving me the binder link to be able to reproduce so easily 🙌🏼

@Emporea
Copy link
Author

Emporea commented Jul 22, 2022

4.5.1 still only works occasionally regarding the "jupyterlab notebook not rendering"
4.4.0 works everytime.

It cant be my firefox alone.

@jsjoeio
Copy link
Contributor

jsjoeio commented Jul 22, 2022

I'm on 4.5.1 on macOS and I cannot reproduce 😢

Screenshot

image

Related

This looks like the exact same issue upstream, right?

microsoft/vscode#132102

Maybe worth dropping a comment on that.

@jsjoeio jsjoeio self-assigned this Aug 9, 2022
@mathematicalmichael
Copy link

regarding the 503... i think this was a temporary microsoft server thing, because it came back up later that day iirc.
so is this issue closable now? are any problems persisting? (i haven't noticed anything but I've been using chrome to be safe lately with the code-server app so I wouldn't have noticed it on firefox).

@Emporea
Copy link
Author

Emporea commented Aug 13, 2022

The problem still persists for me. 4.4.0 has no issue in loading jupyter files. >4.4.0 (for examples latest) on the other hand doesn't load, or only very occasionally.
So I am using 4.4.0 since.
I wont say its definitly an issue with code-server. Maybe its a vscode or jupyter extension bug, but it began to occur after 4.4.0 as stated enough for now. I have tested alot. It still appears to be only firefox tho. Even stock installation without any addons. I just tested chromium once again and everything is working fine with that, even 4.5.1. I even switched to a fedora installation to test it. No luck with firefox.
I never had a 503 issue.

@Emporea
Copy link
Author

Emporea commented Aug 13, 2022

Please test for yourself and tell me if you have the same problem. (firefox)

https://4.4.0.emporea.net
https://4.5.1.emporea.net

Password: coder

Screenshot from 2022-08-13 03-40-07
Screenshot from 2022-08-13 03-40-19

@benz0li
Copy link
Contributor

benz0li commented Aug 13, 2022

Please test for yourself and tell me if you have the same problem. (firefox)

Initially, I had the same problem with your deployment.

Then I cleared all history

clear-all-history

and never had the problem again:

Firefox

@Emporea
Copy link
Author

Emporea commented Aug 13, 2022

Thanks for testing.


4.4.0 (for examples latest) on the other hand doesn't load, or only very occasionally.

Once its working (for example after history cleanup) the file will also load on tab reloads, that's apparently true.

But close test.ipynb and open it up, and it will fail to load once again. (test it please)

@benz0li
Copy link
Contributor

benz0li commented Aug 13, 2022

But close test.ipynb and open it up, and it will fail to load once again. (test it please)

Only the first time. When I close it [while it fails loading] and open it again it loads properly.

@Emporea
Copy link
Author

Emporea commented Aug 13, 2022

Okey. Well I am not able to test under MacOS. I tested several Linux Distros and Windows. Might be working on MacOS, seems to be a weird bug anyway cause every other Browser than Firefox is doing a proper job at loading it.

@benz0li
Copy link
Contributor

benz0li commented Aug 13, 2022

@Emporea I have tested with your deployment at https://4.5.1.emporea.net/

ℹ️ This has nothing to do with the client's operating system.

@jsjoeio jsjoeio modified the milestones: v4.5.2, August 2022 Aug 15, 2022
@jsjoeio
Copy link
Contributor

jsjoeio commented Aug 17, 2022

yeah verify should be first priority and make sure it does not happen in codespaces
i think if we discover this is caused by a bug we wrote then we should write an e2e test otherwise hold off for now

This is our plan for this issue.

@jsjoeio
Copy link
Contributor

jsjoeio commented Aug 18, 2022

Cannot reproduce bug with latest version

I tested this today and it worked as expected.

Steps to Reproduce

  1. download latest code-server - v4.6.0-rc.1
  2. run code-server and open in Firefox
  3. Install Python/Jupyter extensions
  4. Open Jupyter file

Expected

It shows the Jupyter file and runs code.

Actual

It shows the Jupyter file and runs code.

Screenshot

image

Since VS Code (assumingely) tests this on their own, we decided not to add an e2e test for now. If we find out one of our patches introduces a bug or something breaks in the future, we will revisit adding a test.

Closing this for now.

@jsjoeio jsjoeio closed this as not planned Won't fix, can't repro, duplicate, stale Aug 18, 2022
@H4Njx
Copy link

H4Njx commented Jun 14, 2023

But thanks for solving it in theory.

It runs just smoothly [also in practice] at https://demo.jupyter.b-data.ch 😉.

how can i get the Dockerfile about the image registry.gitlab.b-data.ch/jupyterlab/python/base, another way , how put the code-server in jupyterlab, can you give me some help or url about this ? thank you

@benz0li
Copy link
Contributor

benz0li commented Jun 14, 2023

@H4Njx My JupyterLab Python docker stack is publicly available.

Repository: https://github.com/b-data/jupyterlab-python-docker-stack:

Usage > Build image:

cd base && docker build \
  --build-arg PYTHON_VERSION=3.11.4 \
  -t jupyterlab/python/base \
  -f latest.Dockerfile .

latest.Dockerfile: https://github.com/b-data/jupyterlab-python-docker-stack/blob/main/base/latest.Dockerfile
👉 Have a look at the conf files and scripts, too. Some are essential to make it all work together.


Other JupyterLab docker stacks (which also include Python v3.11.4):


ℹ️ Dev Containers for use with Codespaces are a work in progress and will be available soon.

@H4Njx
Copy link

H4Njx commented Jun 14, 2023

@H4Njx My JupyterLab Python docker stack is publicly available.

Repository: https://github.com/b-data/jupyterlab-python-docker-stack:

Usage > Build image:

cd base && docker build \
  --build-arg PYTHON_VERSION=3.11.4 \
  -t jupyterlab/python/base \
  -f latest.Dockerfile .

latest.Dockerfile: https://github.com/b-data/jupyterlab-python-docker-stack/blob/main/base/latest.Dockerfile 👉 Have a look at the conf files and scripts, too. Some are essential to make it all work together.

Other JupyterLab docker stacks (which also include Python v3.11.4):

ℹ️ Dev Containers for use with Codespaces are a work in progress and will be available soon.

thank you so much.

@code-asher code-asher removed the needs-investigation This issue needs to be further investigated label Jul 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants