You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Time estimate of what's necessary to achieve the following
Expand the Python code from a single file into a folder that can be packaged and e.g. uploaded to PyPI. We don't necessarily want to actually upload the template package to PyPI, but someone using the template might want to.
Set up infrastructure to build the wheel so that it can then be imported with micropip.
However the problem remains that the name of the wheel file is hardcoded in the TypeScript code. A simple thing like changing the name of the package or the version number will cause the code to break
It's not possible to query the filesystem from a frontend (you need a real backend server — not our fake WASM backends to do that) so we can't do the equivalent of ls *.whl and take the output of that.
My current best idea is:
when building the wheel with pip (i.e. at the build stage) we somehow get the name of the wheel that's generated. I don't know if pip can do this or if we need to do some hacky thing like parsing pyproject.toml.
dump the name of the wheel into a json file somewhere inside the static dir at a known file path, it could be something like static/wheel.json and its contents would just be a single string
the frontend can then import that json file and look inside to get the path to the wheel, then micropip install that
Followup from #16.
Things to include:
If it's helpful, our previous work on DemoLand:
The text was updated successfully, but these errors were encountered: