WIP: nanobind and Type Stubs#206
Open
philip-paul-mueller wants to merge 39 commits intoghex-org:masterfrom
Open
WIP: nanobind and Type Stubs#206philip-paul-mueller wants to merge 39 commits intoghex-org:masterfrom
nanobind and Type Stubs#206philip-paul-mueller wants to merge 39 commits intoghex-org:masterfrom
Conversation
While the Python package is picked up correctly, the `nanobind-config.cmake` is not. Instead of the one that ships with the Python package the one of the system is found, which is in a cmake directory. However, then the headers are not found. The solution is to move the found path up in the search hirarchy.
But I do not see how `_pyghex` was ever imported? Probably it is injected somehow.
…and why it no longer works.
GHEX needs to find the `nanobind` python package. Before it did not matter because the `REQUIRE` keyword was ignored, see commit `54015fb4c58`. Since the `nanobind` package is installed that thing was probably found. Thus this commit also installes the Python package.
It was a typo.
It now uses a fallback method, in which the Python package is prefered (and requiered in `pip` build mode, whcih is true since it is installed as a dependency) but otherwise it will fall back on the one that is installed on the system. However, I can not test it locally for one reason, but it should work on the CI.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR is on top of PR#198 and introduces Type Stubs.
However, it also fixes some bugs unrelated to that:
find_python_module()such that theREQUIREkeyword is respected.nanobindis found, also allows to run it on Arch.nanobindis found. If it can be found as a Python package it will be used, otherwise it tries to use a system package. This mimics the old beaviour.