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

Is it possible to add notebook metadata, like a description which shows up in the notebook file view? #130

Closed
minad opened this issue Jun 3, 2015 · 6 comments

Comments

@minad
Copy link

minad commented Jun 3, 2015

This would be great for try.jupyter.org and for bundled/containerized notebook archives. Alternatively render the README.md from the current directory under the file view as github does it.

@Carreau
Copy link
Member

Carreau commented Jun 3, 2015

That would require to open/read/parse each file in a directory which we don't want to do.
Try-jupyter is "just" the notebook app, we probably won't add features that don't apply to local server.

@minad
Copy link
Author

minad commented Jun 3, 2015

Well, it needs some effort. But I think it could also be done in a performant way using ajax and by only parsing the first bytes of the ipynb file, which is not a problem unless you have like thousands of ipynb files in a directory, which nobody should have ;)

I would also like to have it for the local server/containers and not only for try.jupyter.org.

@minad
Copy link
Author

minad commented Jun 3, 2015

I think for like a few hundred files you wouldn't even notice if the information is loaded with all the other data. Also you could cache the data in the server.

@Carreau
Copy link
Member

Carreau commented Jun 3, 2015

  1. Problem is many people do run notebooks on NFS filesystems, so you would notice the difference. People already have issues.

  2. The data ordering in json is not guarantied, the bytes would be the last bytes of the fileformat curently, unless people add keys in which case the metadata could be somewhere else.
    It also break the storage layer as we don't assume things are on disk.

Cache is not a solution, people do use other application to modify .ipynb and you don't get notified when the file change.

We did speak about things like that for several hours, like in person at our dev meeting.
There is no reasonable solution as far as we can tell, or the complexity and requirement are probably not worth the gain.

@minad
Copy link
Author

minad commented Jun 3, 2015

Maybe low-priority-background thread or caching+mtime-checking could be the way to handle this. I mean this is not a critical thing it wouldn't be a problem if it loads slowly or shows obsolete information from time to time.

The question about complexity vs. gain is always the question :)

@takluyver
Copy link
Member

For now we want to steer clear of anything putting anything from the files' contents in the directory listing.

It's too slow to do synchronously - I just clocked reading+parsing 10 fairly small ipynb files at 0.5s, and even just opening and reading 500 bytes from each with no parsing at 0.3s. It definitely wouldn't be unreasonable to have several dozen notebooks in one directory, and listings should work into the hundreds of notebooks, whether or not we think it's a good idea to arrange things like that.

As you say, it's possible to do this with smart caching and background threads or processes to update the cache. And we might want to do that at some point. But that sounds like significant extra complexity, and I think there are other things we want to focus on for now.

@Carreau Carreau added this to the wishlist milestone Jun 9, 2015
@minad minad closed this as completed Jan 28, 2017
@minrk minrk modified the milestones: No Action, Backlog Jan 31, 2017
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants