Skip to content

Adopt type hints, and checks for user input

Xiaoyu Wei requested to merge ui-contract into master

The main purpose of this PR is to use pycontracts to track and enforce Array related conventions. Hopefully by doing so I can prevent myself from breaking those rules when developing pytato. It checks for example:

  • names are valid C identifiers
  • dotted names have at least one part
  • what can be a shape of an array

Update:

  • pycontracts is not used due to performance concerns
  • Checks are implemented with type hints and assertions
  • Adds type annotations and mypy CI
Edited by Xiaoyu Wei

Merge request reports

Loading