Skip to content

Add Python type hints to generated model code #50

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 9 commits into
base: main
Choose a base branch
from

Conversation

bact
Copy link
Contributor

@bact bact commented Jul 3, 2025

Add a number of type hints to the generated Python code.

This will partially help the static type analysis.

bact added 5 commits July 1, 2025 19:19
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
It is now defined yet at this stage

Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Copy link

github-actions bot commented Jul 3, 2025

Coverage report

This PR does not seem to contain any modification to coverable code.

bact added 4 commits July 3, 2025 17:01
Use `typing.Set` instead of built-in `set`, for better backward compatibility.

- type hint with built-in `set` is supported since 3.9 inclusive
- type hint with typing.Set is supported back to 3.5 inclusive

Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
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.

1 participant