question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Allow for disabling of nbviewer

See original GitHub issue

Currently, all notebooks from Github show a preview using nbviewer. In some situations this causes a “404: Not Found” message, even though everythign is correct (e.g. when trying to launch a file that is wrapped inside a Docker image).

For example: https://mybinder.org/v2/gh/crestdsl/crestdsl-demo-binder/master?filepath=GettingStarted.ipynb launches a notebook that is not in the repo, but in the Docker image that is launched by the repo.

I believe that providing an url-argument e.g. &preview=false could be useful in these situations to disable the preview (so users aren’t confused).

The concerned code places (as far as I see) are the ParameterizedMainHandler in main.py, where it would be necessary to extract the argument and pass it to the loading.html template. Code to add should be something like preview=self.get_argument('preview', True).

The other part is in the template itself (e.g. near Line 27 ) where a {% if preview %} can be added. (Line 30 already contains a condition that could also be easily extended…)

This issue is to allow feedback / opposition before starting implementing. Thus:

  1. What do you think?
  2. Is my current though process correct? or is my “very simple” solution not as simple after all?

PS: lacking time right now, so PR will come in a few weeks earliest.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:2
  • Comments:12 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
betatimcommented, Aug 23, 2019

With #934 we now don’t show the preview if it would contain an error so I’ll close this issue.

1reaction
fm75commented, Apr 25, 2019

What is GHE?

Sorry, GitHub Enterprise. GitHub, but set up by enterprises, ordinarily not available from the internet.

Read more comments on GitHub >

github_iconTop Results From Across the Web

jupyter/nbviewer - Gitter
I'm using load_roles to create a scope that says allow access to the specified service only to mentioned group. It doesn't seem to...
Read more >
iPython notebook : disable execution - Stack Overflow
I'm running 2 notebook server. The first is private, and need an authentication in order to edit the notebooks. The other one is...
Read more >
Solutions to “Jupyter Notebook Not Rendering on GitHub ...
On this page. 1. NBviewer; 2. Binder; 2. ReviewNB. Your Jupyter Notebook doesn't render on GitHub and you ...
Read more >
error opening tutorial - Google Groups
An error occurred during a connection to nbviewer.ipython.org. This problem can sometimes be caused by disabling or refusing to accept cookies.
Read more >
Configuration options — nbconvert 7.2.7 documentation
Disable this exporter (and any exporters inherited from it). ASCIIDocExporter.exclude_code_cell : Bool. Default: False. This allows you to exclude code cells ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found