Qualtran
Qualtran copied to clipboard
mypy insufficiently strict?
#1345 fixed a bug with PrepareIdentity being constructed with a tuple of QDTypes when it expects a Tuple of Registers. It's surprising mypy didn't catch this. The issue is to figure out why this was allowed.
some reference docs: https://www.attrs.org/en/stable/types.html
could it be because sometimes the fields use field() and sometimes use type annotations?
maybe missing the "type" argument to field?