-
Notifications
You must be signed in to change notification settings - Fork 243
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
iOS support? #1170
Comments
Here's my mobile-forge recipe:
Here's the output from the forge build:
|
It appears that this is because
I looked at trying to add iOS support to maturin, but my changes don't seem to work. Here's the branch with my iOS changes: https://github.com/adamfeuer/maturin/tree/feature/ios-support When I use my changed maturin, I get the following output:
Do you know where the problem lies? In maturin, in pydantic-core, or both? I'm happy to work on this, I'm just not sure where to go from here. |
If rust/maturin/pyo3 can build for iOS, we would absolutely support it. Until then there's nothing we can do. When I checked last, there were virtually no (10s out of 250m) of installs of pydantic v1 on iOS. So it's very rarely used. You might try the wasm build which should work. |
@adamfeuer I think the best course of action is to start with an issue / PR in |
@samuelcolvin @davidhewitt Thanks for getting back to me so fast! I'll pursue the maturin modifications– open a PR and try to get someone with my iOS modifications. I'll report back here. @samuelcolvin In the meantime I could use pydantic v1 because the other Python modules spacy can use v1. It looks like v1 is built by cargo... I can cross compile other rust modules, so I'll give that a shot, if it works it could solve my immediate problem. |
@adamfeuer v1 doesn't have Rust at all ;) |
@davidhewitt Ah! Thank you! That is great! If I need to see the source code, is it on the v1 branch? Do you know how the other iOS users installed pydantic v1? |
v1 is pure python. (It was optimized by Cython at build time, but you can skip that if needed.) I believe the maintenance branch is at https://github.com/pydantic/pydantic/tree/1.10.X-fixes Note that we don't intend to support v1 much longer, and we only merge occasional bugfixes now. |
V1 is on the I've updated my comment above to say.
As you'll see here we already have a preview of running pydantic-core with webassembly, if that runs for you in iOS, it might be the easiest solution. |
@davidhewitt Pure python, perfect. I just built it for iOS using the mobile-forge, so it looks like that will work. I have to rebuild the other stack of software that uses it now. Re: the 1.10.x branch not being supported soon, I understand. If I can get this working with 1.10.x, it will solve my immediate problem, and then I can devote some effort to fixing maturin for iOS. @samuelcolvin I'll try the wasm if the pure python 1.10.x doesn't work. Thank you both so much for your fast help! I'll post here if I get this working, and also let you know what's happening with maturin. |
@messense Thank you for letting me know about this! Wonderful news! |
pydantic and pydantic-core do not appear to build on iOS. Do you plan to add support for it?
Or if it is supported, where can I find documentation for it?
I am using the Beeware mobile-forge and Briefcase and can't generate a binary wheel for pydantic-core, which means I can't install it on iOS.
Many libraries use Pydantic, which blocks them from being used on iOS. For example, spaCy, Presidio, thinc, and others.
The text was updated successfully, but these errors were encountered: