Skip to content
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

Stronger typing #3

Open
2 of 5 tasks
timbernat opened this issue Nov 17, 2023 · 0 comments
Open
2 of 5 tasks

Stronger typing #3

timbernat opened this issue Nov 17, 2023 · 0 comments
Assignees
Labels
enhancement New feature or request planned-feature Changes or additons which are planned by the developer(s)

Comments

@timbernat
Copy link
Owner

timbernat commented Nov 17, 2023

Feel the need to strengthen typing and tyehints in a handful of places:

  • gentutils.typetools : Replace custom Numeric type with builtin numbers.Number
  • genutils.typetools.numpytypes : Implement arithmetic operation into array size generics (“N”, “M”, etc.) to allow arithmetic in annotations (e.g. NDArray[Shape[N/2, M**2], int] ). Relevant starting points can be found in PEP 646
  • genutils.decorators.meta : Add detailed type signature transfer to all meta-decorators
  • genutils.decorators.functional : Fix TypeErrors raised by Callables modified with optional_in_place decorator when passing positional-only args as kwargs
  • openfftools.boxvectors: most of the type-checking here could be migrated to genutils.typetools.numpytypes, while the unit checking could be migrated to unitutils
@timbernat timbernat added enhancement New feature or request planned-feature Changes or additons which are planned by the developer(s) labels Nov 17, 2023
@timbernat timbernat self-assigned this Nov 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request planned-feature Changes or additons which are planned by the developer(s)
Projects
None yet
Development

No branches or pull requests

1 participant