by kolanos · 1y ago · 0 comments
SQLAlchemy does support type annotations [0], am curious what issues you're running into there?
[0]: https://docs.sqlalchemy.org/en/20/orm/extensions/mypy.html
class Foo(Base): name: Mapped[str]
x = Foo() ```
does not get caught as a type error statically, I'm assuming because all records are treated as mutable.
However, `x = Foo(name=2)` also doesn't get caught by pyright, which seems wrong. I could be misusing somehow though.