prisma-engines
prisma-engines copied to clipboard
AST schema doesn't match the actual runtime types for nested creates
In @prisma/[email protected]
/ engines@58369335532e47bdcec77a2f1e7c1fb83a463918
the DMMF schema changed from nested many creates from an array to a non-array type:
![image](https://user-images.githubusercontent.com/5013932/98826987-ee692900-2468-11eb-862b-39f87856a667.png)
This used to be a an array before:
mutation {
user: createOneUser(
data: {
id: "44444"
email: "[email protected]"
username: "johndoe"
name: "John"
posts: {
create: [{ id: "4444444", title: "common", content: "4444444" }]
# ^ is not an array anymore
}
}
) {
id
}
}
However, everything works as expected at runtime, I think just the type information is not correct anymore. You can see that there’s an error that the type doesn’t match, but the query runs:
![image](https://user-images.githubusercontent.com/5013932/98827136-10fb4200-2469-11eb-84ed-aa0b4bbced47.png)