You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The production database is a postgres db with a column named package which is of type array. It's an array of string
In sqlmodel==0.0.8 the above code worked when running tests in sqlite. In sqlmodel==0.0.9, the following error is thrown when trying to run tests:
File "/home/deployer/.conda/envs/060eb14a/lib/python3.9/site-packages/sqlmodel/main.py", line 432, in get_column_from_field
sa_type = get_sqlalchemy_type(field)
File "/home/deployer/.conda/envs/060eb14a/lib/python3.9/site-packages/sqlmodel/main.py", line 425, in get_sqlalchemy_type
raise ValueError(f"The field {field.name} has no matching SQLAlchemy type")
ValueError: The field package has no matching SQLAlchemy type
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
First Check
Commit to Help
Example Code
Description
The production database is a postgres db with a column named
package
which is of type array. It's an array of stringIn
sqlmodel==0.0.8
the above code worked when running tests in sqlite. Insqlmodel==0.0.9
, the following error is thrown when trying to run tests:I've fixed the issue with doing the following:
I checked the diff and saw the code change:
which is what's causing this to stop working. I'm wondering is this a side effect of a bug fix or is this in preparation for Pydantic 2?
Thank you.
Operating System
Linux
Operating System Details
No response
SQLModel Version
0.0.9
Python Version
3.10
Additional Context
No response
Beta Was this translation helpful? Give feedback.
All reactions