jupyter-ui
jupyter-ui copied to clipboard
Save from notebookActions is not working anymore
The following snippet is the one I've been using with previous versions. I'm not really sure what's the reason it's not working anymore.
onClick={e => {
e.preventDefault();
dispatch(
notebookActions.save.started({uid: notebookId, date: new Date()})
);
}}
I receive the following error:
Also in the console I can see:
Access to fetch at 'https://myjupyterserver.com/api/jupyter/api/contents/kernel-a2f3db0c-9942-4d78-bd00-1f7f99f45562?content=0&hash=1&1712596308613' from origin 'https://myclient.com' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header contains multiple values 'https://myclient1.com, https://myclient2.com, http://localhost:3000', but only one is allowed. Have the server send the header with a valid value, or, if an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.
GET https://myjupyterserver.com/api/jupyter/api/contents/kernel-a2f3db0c-9942-4d78-bd00-1f7f99f45562?content=0&hash=1&1712596308613 net::ERR_FAILED 404 (Not Found)
I'm using version 0.9.8 of jupyter-react and next.js 14. Thanks in advance!
This maybe (not sure) an similar issue as the one reported by @dbhagesh on https://github.com/datalayer/jupyter-ui/issues/195
I will find some time this week to investigate.
Thank you @echarles!
@BrandonEscamilla Can you try with 0.10.0? I was not able to reproduce the specific issue you reported, but brought a fix for another similar issue https://github.com/datalayer/jupyter-ui/issues/195#issuecomment-2053937986