Support for newer API version #541
mattiapenati
started this conversation in
Ideas
Replies: 1 comment
-
|
Thank you for continuing to push this. I recently wondered if we could make use of cargo's metadata table together with extending our build script to make API selection possible via cfgs like PyO3. Something like this: # Cargo.toml
# ...
[package.metadata.numpy]
api = "1.18"which would then enable the flags |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
The current implementation is targeting the ABI v2 and the API v1.15. This choice ensures a wide compatibility of the extensions built using this crate. As already discussed in #534 it can be useful for extension's developers to choose the target API version, in order to make the newer features of NumPy available.
I try to summarize the previous discussion:
It seems that an easy solution to provide API selection is not feasible, both at runtime and compile time. The usage of mutually exclusive features was not discussed, I think it is a viable solution and it is hard for me to think of an other solution. I know that it is not without drawbacks, in particular a compilation error arises if multiple incompatible features are enabled in the dependency graph, but how common is this situation?
I'm going to cite all the users that have participated in the previous discussion. I hope you are already interested in this topic, if not, I apologize for the noise. @Icxolu @ngoldbaum @seberg
Beta Was this translation helpful? Give feedback.
All reactions