Open RobertCraigie opened 3 years ago
Something I didn't consider when creating this issue is the file size limit on PyPi, this appears to be 60MB.
Running a naive tar -zcvf binaries.tar.gz BINARIES_DIR
creates a 79MB tarball on MacOS :/
I don't know what compression would be used when actually packaging the files.
Successfully uploaded the packaged binaries to testpypi
The only concern I have with this is increasing install times on slower connections, however this could probably be mitigated by packaging a platform agnostic wheel that doesn't include the binaries and then users can install with --platform=none
if they need to.
I do not know if this is possible though.
Upon further thought I do not know if the slow download time would matter that much as the binaries would have to be downloaded anyway to use the library.
Could use https://github.com/ziglang/zig-pypi for inspiration.
Another concern with this is that the binaries would be redundant when using either the Prisma Data Proxy or the Native query engine although support for these has not been implemented yet
Problem
We currently only package one universal wheel when we could make use of platform dependent wheels to improve first-time user experience, when someone installs a python package they don't expect to have to wait while more binaries are downloaded.
Suggested solution
Update
setup.py
wheel building to build platform dependent wheels for every platform that prisma supports, we could also fall back to building the rust binaries on the user's machine if they are on an unsupported platform but thats outside the scope of this issue.