-
Notifications
You must be signed in to change notification settings - Fork 200
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
✨ NEW: Add Deepnote launch option for notebooks #385
✨ NEW: Add Deepnote launch option for notebooks #385
Conversation
Thanks for submitting your first pull request! You are awesome! 🤗 |
e08298c
to
db0c15c
Compare
I just tried to build with this theme, with this result (example page): https://uob-ds.github.io/cfd2021/intro/Plotting_the_Classics.html I do get a Deepnote link icon, but the generated URL is This does open Deepnote in a new project, but does not clone the textbook repository, so leaves me looking at the default empty Deepnote project, with the default near-empty "notebook.ipynb" file as the only file, and "Please select a file" at the center of the page. |
Thanks @matthew-brett for testing it out (and thanks @jakubzitny for the PR, sorry for the slowness here, just being split in a million directions at once). Can you confirm the behavior that Matt describes? I think we would want the launch buttons to all behave the same way (launching into an environment + grabbing the content from the source files and opening it) |
Thanks a lot for testing this @matthew-brett, there is some escape problem when the notebook is inside a directory, let me test it a bit more and come up with a proper solution. |
Actually - I think the problem was mine - I didn't push the branch that I was pointing to, up to Github, and I have now done that. I think the links are working correctly - see the Deepnote link at the top of: https://uob-ds.github.io/cfd2021/intro/Another_Kind_Of_Character.html |
@jakubzitny - this does work, but it's a bit inconvenient, as I believe every click takes the user to a new public project, even a click on the same page. This means it will be difficult for the students to keep track of their edits to the book notebooks. Does it also mean it is possible to saturate the free public project count, per user? Is there any way to form the link such that a click does one of the following (in order of preference):
|
db0c15c
to
3f138d3
Compare
Yes @matthew-brett, you're right. This is a plain "copy" of the functionality that both Colab and Binder offer, where you also get a new "instance" every time. What you're proposing totally makes sense, but the scope of designing that UX properly is quite large imo. We'd need to figure out a way to update the existing project whenever new version of the book (or the notebook in gh repo) is updated and figure out what version we wanna open. If there are changes in the existing Deepnote project what do we do with them. There might even be conflicts between changes in DN and on GH, so I think this is something we could continue discussion on, but I am not sure the right place is this PR. Personally, I'd love to see the usage of Deepnote via this button in jupyter books, and then iterate if the usage is really popular. But in any case, there is a possibility for you to link an existing Deepnote project within your book/page (this could even include a custom environment with Dockerfile) and your readers can definitely open that one directly (and clone it and build on top). @choldgraf I updated the PR, could you please approve my workflows, so we can see that all tests are passing properly? |
@jacobtomlinson - only to say - that problem - of merging - is one of the problems that makes nbgitpuller work so well. I don't know precisely how it does this, but it pursues an extremely conservative merge strategy that seems never to replace local edits, done by the students, but nevertheless pick up my edits to later chapters and notebooks. I wonder if they use something like |
Just to update on merging and nbgitpuller, for my information as much as anything: nbgitpuller automatic merging behavior It does use the -Xours Git merge strategy. |
Hi @matthew-brett @choldgraf, we've added a request to keep the state of existing "clone" of a book (or GitHub repo in general) in Deepnote space. But it's not on the top priority list. I'd suggest merging this (as the functionality with other notebooks is similar) and whenever we come up with the improved version, it'll work instantly. I think this can already help a bunch of folks, at least the ones requesting it on our side. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I updated the tests so that we're now testing for this one!
also noticed a class that wasn't named properly, but other than that I think this looks good if the tests are happy.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK I think that there are likely still some improvements to make on the UX of launch buttons, but don't need to block on this PR. I opened up #462 to discuss and track that work, so let's get this in and iterate! 🚀
Adding a possibility to use Deepnote for launching notebooks next to Binder and Colab. Already discussed it here.