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 database type annotations in the Prisma schema, like @db.Uuid, are not being included in the DMMF that is passed to the generators. However, as of the 5.23.0 timeframe, this information is available from the Prisma CLI. It's quite useful for certain custom generators.
Suggested solution
Add this line in class Field in generator/models.py:
This does require setting PRISMA_VERSION to 6.0.0 or later to get the native type information, but does not cause problems with the default version of 5.17.0. The native_type field is simply absent. Using 6.0.0 for custom generators appears to cause no issues.
The text was updated successfully, but these errors were encountered:
Problem
The database type annotations in the Prisma schema, like @db.Uuid, are not being included in the DMMF that is passed to the generators. However, as of the 5.23.0 timeframe, this information is available from the Prisma CLI. It's quite useful for certain custom generators.
Suggested solution
Add this line in
class Field
ingenerator/models.py
:Additional context
This does require setting PRISMA_VERSION to 6.0.0 or later to get the native type information, but does not cause problems with the default version of 5.17.0. The native_type field is simply absent. Using 6.0.0 for custom generators appears to cause no issues.
The text was updated successfully, but these errors were encountered: