Skip to content

Apply __futre__.annotations to skbuild_model #1053

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

LecrisUT
Copy link
Collaborator

@LecrisUT LecrisUT commented Apr 23, 2025

This thing is getting in the way a lot

Edit: Yeah, had a hunch it would blow up in various places, but there are more issues than I would have expected

@henryiii
Copy link
Collaborator

We probably can't do this until we depend on something like 3.10+. At that point we could even drop the future import. Generally, the future import means you aren't using the types at runtime, but we are for this module.

@LecrisUT
Copy link
Collaborator Author

Generally, the future import means you aren't using the types at runtime, but we are for this module.

I thought dataclasses are still safe for that.

But any clue on why 3.12 and such are failing?

@henryiii
Copy link
Collaborator

We are processing the type annotations. Pretty much most of this file is for type annotation processing: https://github.com/scikit-build/scikit-build-core/blob/main/src/scikit_build_core/settings/sources.py

I'm guessing those are failing because it's not rendering one of the strings somewhere (in the above linked file). I think we should do that, so likely there's something missing. It might be that you'd need annotationlib (3.14+, backport in typing_extensions), though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants