-
Notifications
You must be signed in to change notification settings - Fork 159
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
How to avoid 403: Forbidden Error? #408
Comments
I just tested this locally with WSL, and had no problems. What I run is: nbdiff-web --browser none base_notebook.ipynb [remote_notebook.ipynb] and then connect to the 127.0.0.1 with the port listed in the output, or use The |
I didn't specify the none option for the browser argument, since I thought it was the default in the argparser. Anyway I did try again with what you suggested and I've got the same error, this is the command line output: [I nbdimeserver:374] Listening on 127.0.0.1, port 51653
[W webutil:18] No web browser found: could not locate runnable browser.
[I webutil:29] URL: http://127.0.0.1:51653/difftool
[W handlers:443] Blocking request with non-local 'Host' 127.0.0.1 (127.0.0.1:51653). If the notebook should be accessible at that name, set NotebookApp.allow_remote_access to disable the check.
[W log:48] 403 GET /difftool (127.0.0.1) 14.13ms referer=None Also I forgot to mention that I'm trying to use the tool to check a diff between two of my local commits, i.e: nbdiff-web --browser none commit_a [commit_b] I don't know if that may be the problem. |
Thanks for including the full log. That warning message is from notebook 5.6 (nbdime reuses some of the notebook server logic). Which python version are you on? And what do you get if you run the following code on the same python that is running nbdime: import ipaddress
addr = ipaddress.ip_address('127.0.0.1')
print (addr.is_loopback) |
I'm on Python 2.7.15 (using a specific conda env) and I get |
@giovannibonaccorsi can you connect if you specify 'localhost' instead of '127.0.0.1'? I think this is a bug in the notebook that should be fixed by |
@minrk I ran again with localhost as ip and I've got the same error. This is the code:
And this is the full log:
On the other hand I've got the unicode error you're referring to in 3809 when doing |
@giovannibonaccorsi If you feel comfortable with it, would you mind installing the latest version from master (after #409) to ensure that the workaround we put in works for you (both with |
@vidartf I've time to test the workaround but I need some help with the installation,sorry. |
I just released a new version, so try installing that instead, and check if it works! |
@vidartf Hi, I just installed the new version and everything works fine. Thanks a lot for your help! |
I'm trying to access the
nbdiff-web
visualization l but I get a 403 error when I open the URL.One possible cause maybe that I'm working with Anaconda on a Windows Linux Subsystem. Since the Linux distribution has no browser I usually access notebooks on a localhost port via Chrome from outside the Linux subsystem.
I've tried to do the same with
nbdiff-web
by adding the following line arguments--ip localhost -p 8888 --base-url <the folder I'm working>
, but with no success.Is there something else I should try?
Thanks.
The text was updated successfully, but these errors were encountered: