sqlalchemy2-stubs icon indicating copy to clipboard operation
sqlalchemy2-stubs copied to clipboard

PEP-484 typing stubs for SQLAlchemy 1.4

Results 45 sqlalchemy2-stubs issues
Sort by recently updated
recently updated
newest added
trafficstars

**Describe the bug** If columns are created with functions wrapping `sqlalchemy.Column` (e.g. `NotNullColumn = functools.partial(sqlalchemy.Column, nullable=False)`) they are not recognised by the type checker in places such as initialisation. **Expected...

bug
mypy

**Is your feature request related to a problem? Please describe.** I authored https://github.com/sqlalchemy/sqlalchemy/issues/5777 which added a typevar to `run_sync` to infer the return value. At that time is was not...

enhancement

ref: #14 If i use `declared_attr` in the upper `mixin` class, i get `Name "Carrier" is not defined` error. Using import like below, which is not used anywhere, fixes the...

requires triage

Currently missing files: - [ ] dialects/sqlite/aiosqlite.py - [ ] dialects/mysql/asyncmy.py maybe some other?

missing type

**Describe the bug** When adding the `server_default` kwarg to a Column declarative_attr, mypy complains like this: ``` error: Cannot infer type argument 1 of "Column" ``` not really sure if...

bug

all ORM functions that are used in declarative are now made separate from the classes they refer towards in all cases and indicate the return type of Any so they...

This is a try of using the mikes provided code in hybrids but it does not work propertly. Can you take a look @zzzeek ? ### Description Fixes: #171 ###...

when the plugin is not supported, for example when using other type checkers. ### Description This was taken from the dropbox stubs. Fixes #170 ### Checklist This pull request is:...

**Describe the bug** type inferenced is int **Expected behavior** type inferenced should be Uninon of int and Column ![image](https://user-images.githubusercontent.com/46264158/136487904-104abde9-7841-4128-8d41-7ed61228db3b.png) **To Reproduce** session.query(Object).order_by(asc(Object.field)) where field is of type Column(Integer) **Please do...

bug

**Describe the bug** Not sure how to exactly explain it, but if I use a union, mapped and cast together, there is something wrong. **Expected behavior** No mypy error **To...

bug
mypy plugin