Introspection: MongoDB: Warnings mention Native Types instead of PSL types (e.g. Document instead of Json) #12321
Labels
domain/schema
Issue in the "Schema" domain: Prisma Schema, Introspection, Migrations etc.
kind/improvement
An improvement to existing feature and code.
topic: introspection
topic: mongodb
topic: native database types
Milestone
Now that we use
Json
for properties with different types, we might want to tweak the language used in the comment and CLI warning:Example 1, (since Json is picked as default with engine PR)
Here for the field
field: "numberOrString3"
thechosen data type
isDocument
but the type in theschema.prisma
file will beJson
See
db pull
testprisma/packages/migrate/src/__tests__/DbPull.test.ts
Lines 752 to 807 in 755d81b
Example 2 (Before the default changed to Json)
Here for the field
field: "depth"
thechosen data type
isInt32
but the type in theschema.prisma
file will beInt
See https://github.com/prisma/introspection-ci/blob/4c4b4f7aeaa5d0eea96d4a3d00630c8a52b3e3f9/introspection-analysis/output/mongodb_public/sample_geospatial_stderr.log
Internal thread https://prisma-company.slack.com/archives/C4GCG53BP/p1647246722174479
MongoDB data
Note: introspection-ci results when default changed to Json https://github.com/prisma/introspection-ci/commit/b362f3e9ab0361a9b9efa96c382359303273cc4d
The text was updated successfully, but these errors were encountered: