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
When inspecting db (after all migrations) getting this error:
Stack trace:
Traceback (most recent call last):
File "/usr/local/bin/aerich", line 8, in<module>sys.exit(main())
^^^^^^
File "/usr/local/lib/python3.11/site-packages/aerich/cli.py", line 265, in main
cli()
File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1157, in __call__
return self.main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1688, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/click/core.py", line 783, in invoke
return __callback(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/click/decorators.py", line 33, in new_func
returnf(get_current_context(), *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aerich/cli.py", line 31, in wrapper
loop.run_until_complete(f(*args, **kwargs))
File "/usr/local/lib/python3.11/asyncio/base_events.py", line 653, in run_until_complete
returnfuture.result()
^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aerich/cli.py", line 260, in inspectdb
ret = await command.inspectdb(table)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aerich/__init__.py", line 124, in inspectdb
return await inspect.inspect()
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aerich/inspectdb/__init__.py", line 95, in inspect
columns = await self.get_columns(table)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aerich/inspectdb/postgres.py", line 62, in get_columns
Column(
File "/usr/local/lib/python3.11/site-packages/pydantic/main.py", line 165, in __init__
__pydantic_self__.__pydantic_validator__.validate_python(data, self_instance=__pydantic_self__)
pydantic_core._pydantic_core.ValidationError: 1 validation error for Column
extra
Field required [type=missing, input_value={'name': 'id', 'data_type...: False, 'index': False}, input_type=dict] For further information visit https://errors.pydantic.dev/2.3/v/missing
Libs:
aerich==0.7.2
asyncpg==0.28.0
tortoise-orm==0.20.0
pydantic==2.3.0
pydantic_core==2.6.3
Not sure which additional info to provide. All tables have custom names with Meta class, also I have 2 custom field types:
classNativeDatetimeField(Field[datetime.datetime], datetime.datetime):
SQL_TYPE="timestamp without time zone"classNativeDatetimeFieldNow(Field[datetime.datetime], datetime.datetime):
SQL_TYPE="timestamp without time zone DEFAULT now()"
Any suggestions what could it be?
The text was updated successfully, but these errors were encountered:
Hi log2ice, you are right when you saying that we must latest source code but when i'm trying pip install aerich
the latest version is 0.7.2, and the pydantic validation error persists, and when i'm checking the code on github i can see the problem is solved, and i think so, the author have to update the python (pypi) repository please.
When inspecting db (after all migrations) getting this error:
Stack trace:
Libs:
Not sure which additional info to provide. All tables have custom names with Meta class, also I have 2 custom field types:
Any suggestions what could it be?
The text was updated successfully, but these errors were encountered: