Closed wmay closed 1 year ago
That's a bug. Thanks.
Commit f47d1f6.
Oh, this still has a minor issue. The "login" part of the URL needs to be removed. Thanks for getting to this so quickly though!
I still get the 403 error. I added a bunch of messages to ein:query-prepare-header
to print out the variables, after everything is assigned by let*
. Here's what I got:
host is example.com
path is /folder/login
`(zerop (length path))` is nil
`(file-name-as-directory path)` is /folder/login/
cookies is nil
xsrf is nil
I'm afraid the beatings will continue until morale improves.
Commit 8838910 is another try at this.
Still getting a 403 error. Here are the values I'm getting within ein:query-prepare-header
now:
host is example.com
path is nil
`(ein:notebooklist-parse-nbpath url)` is nil
`(ein:notebooklist-keys)` is nil
`(stringp path)` is nil
cookies is nil
xsrf is nil
I also got the error (from ein:notebooklist-parse-nbpath
I think):
Error (ein): https://example.com/folder/login not among: nil
Okay, I resorted to blindly matching all of "/folder/login/", "/folder/" and "/" until it finds an xsrf cookie. Commit 32e2681.
This brute-force approach should only apply the first go-round, after which ein:notebooklist-parse-nbpath
will have registered "/folder/" as the canonical url.
That fixed it, I'm able to log in now. Thanks!
Problem description
I get a 403 error trying to log in to a remote jupyterlab with a folder in the URL, like example.com/folder. Jupyterlab sends a response complaining that
'_xsrf' argument missing from POST
.I finally got it to work by altering
ein:query-prepare-header
:Steps to reproduce the problem
Try to log in to a jupyterlab server with a folder in the URL.
System info:
Logs:
request-log:
ein:log-all: