jupyter: Concurrent file serving is broken?

I’ve filled this here but as it seems bug report of that repository is not that active and my previous bug didn’t get any response I feel I should report it here also,

(rest is copied from https://github.com/jupyter/jupyter_server/issues/11, feel free close one of the files)


I am experiencing a very weird issue with jupyter that possibly is a regression. Here is its steps to reproduce:

Create a notebook, put this code on first cell to create test images:

from PIL import Image
from PIL import ImageDraw

for i in range(1, 21):
    img = Image.new('RGBA', (10, 10), 255)
    draw = ImageDraw.Draw(img)
    draw.text((0, 0), str(i), fill="black")
    img.save(str(i) + '.png')

Put this on the next cell as markdown:

<img src="1.png" width="30">
<img src="2.png" width="30">
<img src="3.png" width="30">
<img src="4.png" width="30">
<img src="5.png" width="30">
<img src="6.png" width="30">
<img src="7.png" width="30">
<img src="8.png" width="30">
<img src="9.png" width="30">
<img src="10.png" width="30">
<img src="11.png" width="30">
<img src="12.png" width="30">
<img src="13.png" width="30">
<img src="14.png" width="30">
<img src="15.png" width="30">
<img src="17.png" width="30">
<img src="18.png" width="30">
<img src="19.png" width="30">
<img src="20.png" width="30">

Actual: I see such result this, differently every time:

screen shot 2017-10-08 at 4 59 12 pm

Expected: To images loaded correctly.

My system: jupyter --version: 4.3.0 macOS High Sierra

I can reproduce this very consistently on my setup, Is jupyter server somehow fails on serving concurrent requests or something else is wrong?

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 25 (14 by maintainers)

Most upvoted comments

Figured it out. The way AuthenticatedFilesHandler was being called involved mixing Handler instances in a not-entirely-safe way. I’ve switched how the files handler is registered so that only the CM’s handler is registered and fully initialized, rather than trying to handoff from one handler to another.