I have several notebooks that use jupyter-notebookparams. Until this week (2023-10-09), they worked fine, but now result in a 404 error. The notebook continues to work if not called with a parameter so I think the problem must have been caused by a change on binder that has broken notebookparams. Here is a link to the notebook with a parameter value that now fails. Here is a link to the same notebook with no parameter value which still works. Does anyone know what could be wrong and how to fix it? Thanks.
fresh build of images for my Binder using the r-conda repo as a template not working to allow switching to RStudio, either using the URL or the RStudio tile in the launcher, see the related Discourse thread here.
They all involve MyBinder sessions parsing the URL and doing something beyond the basics of switching between JupyterLab and classic interface. I just posted about my suspicions about two if these here.
At the time that issue was written, it didn’t work in JupyterLab and now all the tech is based on that, by default. I believe it would need to opt in to using NbClassic to continue to work. I know from the example JupyterLab 4 + Notebook 7 + NBClassic on Binder it is possible to run NbClassic alongside the others via MyBinder. You can go there and click on the link to launch. When the session comes up replace tree at the end with nbclassic. You may want to try adding nbclassic==1.0.0 to your configuration file requirements.txt to at least get it there. However, I don’t know the URL combo to specify how to launch directly into that interface yet. And then even if that works, you may finally hit the problem with the URL parsing/resolving being a little ‘off’ lately. (I would try all that first in your fork of the main notebookparams repo: GitHub - berniegsfc/jupyter-notebookparams: Takes query parameters from a url to create the first cell of a jupyter notebook. ).
@berniegsfc we’ve redeployed the original change, with a fix (jupyterhub/binderhub#1774). Your link continues to work for me! Can you try it out and let me know if you have problems?
We’re working on cleaning up the binderhub frontend code, and making it more robust (adding unit tests, refactoring, type checks, etc). This break was unfortunately a side effect of that, but hopefully the added tests and robustness will make things better in the long run - you’ll see that the fix PR has more lines of test than fix!
I have tested all of my notebooks that use notebookparams and they all work now. Thank you and everyone who helped to resolve this quickly. I is good that you have added tests for this type of problem. I do not usually test my binder notebooks unless I make a change. But last week, the notebooks were tested in preparation for a presentation at the Data, Analysis, and Software in Heliophysics workshop. Binder is a great resource to demonstrate small, example notebook.