Marius Chisa
05/04/2022, 10:48 AMException in thread "main" java.util.concurrent.TimeoutException: Futures timed out after [30 seconds]
Daniell
05/09/2022, 12:00 PM→ npx prisma-upgrade ./prisma.disable.yml prisma/schema.prisma
Error Error parsing the Prisma 2 file.
Are you sure "/backend/prisma/schema.prisma" is a valid Prisma 2 schema file?
Run `prisma-upgrade -h` for more details.
Stack Trace:
SyntaxError: Expected "=", "}", [ \t\n\r], or [A-Za-z] but "@" found.
I am getting this error after running npx prisma db pull
on a Prisma 1 generated database, unfortunately I cannot share the generated file but hope to get some indication on how I could solve this. When I open the file in my editor with the Prisma extension it does not show any errorslawjolla
05/19/2022, 5:14 PMLars Ivar Igesund
05/19/2022, 5:20 PMshibi
05/25/2022, 10:00 AMtype User {
id: String
stats: Stats
}
type Stats {
id: String
}
I have User in prisma1 and prisma2. And I have stats in prisma2 only.
When I am overriding whole user query to prisma2 it works good with custom resolver to receive stats:
User {
stats: (parent, args, context) => {
return context.newPrisma.user.findUnique({
where: { id: parent.id },
}).stats();
}
}
But when I won't override user query to new prisma and will use old prisma to fetch user, it won't use stats resolver 😞
Is it possible to somehow force graphql/prisma to use prisma2 resolver inside prisma1 query?
I've noticed that when I am using prisma1 for query it tries to use relation table _UserToStats which I ofc don't have as I've migrated Stats and it's relation to User
to prisma2. Is it possible to tell graphql yoga not to append relation table part? And use my custom resolver for stats, which will query it based on prisma2?
This is only simple example, application is complex so I would like to somehow keep it consistent for now and migrate it gradually.
Thanks in advance and have a great day!Marcus
06/07/2022, 8:26 AMcreatedAt_lte:
on the outside and transform it to createdAt: { lte:
for prisma.
where: {createdAt_lte:"", createdAt_gt:""} => where: {createdAt:{lte:"",gt:""}}
Of course it's easy to write a recursive mapper for this. But I think there used to be a community driven project for exactly this problem. But I can't find it anymore.
Do you know a module for this?Matias
06/15/2022, 12:59 PMLars Ivar Igesund
06/21/2022, 3:51 PMPedro Roque
06/23/2022, 9:40 AMLars Ivar Igesund
06/23/2022, 10:12 AMandrewicarlson
06/23/2022, 12:47 PMPedro Roque
06/23/2022, 12:50 PMCREATE TYPE "default$default"."Type" AS ENUM ('BULK', 'SHOP', 'TBC');
ALTER TABLE "default$default"."Order" ALTER COLUMN "type" SET DATA TYPE "default$default"."Type" using "type"::"default$default"."Type";
ERROR: default for column "type" cannot be cast automatically to type "default$default"."Type"
SQL state: 42804
Any ideias why this is happening? I'm still new to postgresMatias
06/24/2022, 2:46 PMprisma1 deploy --no-migrate
but I'm receiving migration validation errors like this one: The underlying column for the field "status" has an incompatible type. The field has type "Enum" and the column has type "String"
.
I have two questions:
1. Why if I use the --no-migrate flag prisma is running migration validations?
2. Why the error says that Enum is not compatible with String? Prisma creates Enum datamodel field as varchar(191). Is this a bug?Matias
06/27/2022, 8:31 PMDeadlock found when trying to get lock; try restarting transaction
.Vladi Stevanovic
Vladi Stevanovic
Matias
07/05/2022, 2:31 PMMatias
07/21/2022, 3:13 PMVladi Stevanovic
Quentin Gilon
08/08/2022, 3:31 PMERROR: There is a relation ambiguity during the migration. Please first name the old relation on your schema. The ambiguity is on a relation between CustomerSubscription and Plan. Please name relations or change the schema in steps.
{
"data": {
"deploy": null
},
"errors": [
{
"locations": [
{
"line": 2,
"column": 9
}
],
"path": [
"deploy"
],
"code": 3018,
"message": "There is a relation ambiguity during the migration. Please first name the old relation on your schema. The ambiguity is on a relation between CustomerSubscription and Plan. Please name relations or change the schema in steps.",
"requestId": "local:cl6diaxtq001t0818wi9ql9jp"
}
],
"status": 200
}
Pedro Roque
08/16/2022, 11:11 AMPedro Roque
08/18/2022, 2:46 PMLars Ivar Igesund
08/19/2022, 1:03 PMVladi Stevanovic
Aaron Markle
08/24/2022, 3:31 PMlawjolla
08/26/2022, 4:44 PMMaciek K
08/29/2022, 12:27 PMKevin Justal
08/30/2022, 7:27 AMJeff Gardner
09/01/2022, 5:17 PMLars Ivar Igesund
09/01/2022, 5:20 PM