-
Notifications
You must be signed in to change notification settings - Fork 64
Fix empty file creation #426
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
Conversation
|
This is not the final solution, but I don't think what we had could work in the general case. |
|
Thanks @davidbrochart ! Would it make sense to move this logic in the front-end? |
|
Integration tests report: appsharing.space |
|
@davidbrochart Why do we need to remove this ? |
|
I think this deserves more discussion, but my take is that the kernel's file system is in the general case unrelated to the JupyterLab file system. I know that in JupyterLite we can mount the frontend file system in the backend filesystem, but this is usually not the case in JupyterLab. Therefore I think that the kernel should always use a special API (the "Jupyter filesystem API") to access files. This API could be a Jupyter widget, and the data might travel from the kernel to the frontend, and back to the backend, which may look unnecessary at first point, but in the general case the "kernel backend" is not the same as the "server backend". |
|
On a short term, can we solve this by only making file-system calls from the front-end? So this file creation logic could be moved in our Lumino plugin? |
|
Sure, but an even faster workaround is to just remove that logic, which I think is not present in JupyterCAD? |
It may be confusing for user to provide a path, have a widget with no error but cannot retrieve the file later, no ? |
|
Yeah unfortunately removing this without a replacement is not an option IMO. Users get confused the file is not created. We should find a good solution and port it to JupyterCAD. |
|
I think that a Jupyter widget implementing a filesystem API should not be very complicated, and benefit both JupyterGIS and JupyterCAD (and even beyond). |
|
Although I fully agree with your Jupyter filesystem API idea and how it would solve our issues here, having it a jupyter widget going through the front-end is not ideal IMO. I'd love a solution that don't require a browser front-end. |
|
Well the Jupyter widgets protocol (and |
|
Good point 👍🏽 |
|
Since we already have a widget here, creating the file ourselves from there, in the front-end, may be the easiest for now. |
|
Closing, I'll include it as part of #412 |
Description
See #425, #352.
Checklist
Resolves #XXX.Failing lint checks can be resolved with:
pre-commit run --all-filesjlpm run lint📚 Documentation preview: https://jupytergis--426.org.readthedocs.build/en/426/
💡 JupyterLite preview: https://jupytergis--426.org.readthedocs.build/en/426/lite