Cigoler
12/10/2019, 10:24 AMCigoler
12/10/2019, 11:04 AMAndrew
12/10/2019, 7:35 PMnobyf
12/11/2019, 7:52 AMnobyf
12/11/2019, 7:55 AMHans Chen
12/11/2019, 8:57 AMHans Chen
12/11/2019, 8:58 AMinno
12/11/2019, 9:19 AMHans Chen
12/11/2019, 9:29 AMHans Chen
12/11/2019, 9:29 AMSorin Cristea
12/11/2019, 4:54 PMSorin Cristea
12/11/2019, 4:55 PMSorin Cristea
12/11/2019, 4:55 PM[
"Your token is invalid. It might have expired or you might be using a token from a different project."
]
Sorin Cristea
12/11/2019, 4:55 PMvnadygin
12/11/2019, 6:07 PMprisma deploy
it also updates the DB scheme. After that, the second instance try to update Prisma scheme with prisma deploy
, but no changes found. Any way we can update the prisma Graphql model from already updated database?🙏🙏🙏Nesh
12/11/2019, 6:51 PMprisma reset
The command runs and ends successfully but all the tables still have data.Nesh
12/11/2019, 6:52 PMprisma deploy
The command ends successfully but there are still errors in deployment
You can see the errors when you have export DEBUG="*"
But the command ends in success which makes it unreliable to use in CI/CDMohammed Nasir
12/11/2019, 6:58 PMJakub Sys
12/12/2019, 9:16 AMMatthew Blode
12/12/2019, 10:26 PMMohammed Nasir
12/14/2019, 12:44 AMMohammed Nasir
12/14/2019, 12:48 AM[INFO] Fatal error during deployment worker initialization: akka.pattern.AskTimeoutException: Ask timed out on [Actor[<akka://single-server/user/$e#-921169135]>] after [300000 ms]. Sender[null] sent message of type "com.prisma.deploy.migration.migrator.DeploymentProtocol$Initialize$".
23:39:28
akka.pattern.AskTimeoutException: Ask timed out on [Actor[<akka://single-server/user/$e#-921169135]>] after [300000 ms]. Sender[null] sent message of type "com.prisma.deploy.migration.migrator.DeploymentProtocol$Initia
Lars Ivar Igesund
12/14/2019, 10:43 AMtype User {
id: ID! @id
name: String!
leaderOfTeams: [Team!]! @relation(name: "TeamLeader")
}
type Team {
id: ID! @id
name: String!
teamLeader: User @relation(name: "TeamLeader", link: INLINE)
}
I have used nexus-prisma to generate graphql, use apollo to connect. I have created a couple of users, and now I want to create a team and connect the teamLeader field to one of the users. Everything seems to work fine until one of the final steps. Then, I get
GraphQLError: Variable "$data" got invalid value "5df286a724aa9a0007c2ae91" at "data.teamLeader"; Expected type UserCreateOneWithoutL
eaderOfTeamsInput to be an object.
So I suppose this is because teamLeader has the type User in the GraphQL-schema, whereas the actual database is supposed to store the id (a string). Of course, using the teamLeader field should typically resolve to a User object, so I suppose that is correct, but then there need to be something in the resolvers (probably both query and mutation) to handle this.
Anyone know what I am missing here?michieldewilde
12/14/2019, 4:13 PMRob
12/15/2019, 6:32 PMInvalid photon.() invocation
for a while. After googling around for the error, it typically seemed like most people resolved the issue with upgrading prisma2 to preview-17 or higher. I am on the latest preview of Prisma, but just can't seem to resolve the error. My app is running in Docker Compose using Windows WSL2 Ubuntu.
I have the following versions installed:
"@prisma/photon": "^2.0.0-preview018.2",
"prisma2": "^2.0.0-preview018.2",
"nexus": "^0.12.0-rc.5",
"nexus-prisma": "^0.6.1",
One thing I have started noticing is that my prismaPath
is undefined in the Photon instance added to the ApolloServer's context, and I assume that I need to do something to populate that value but googling for prisma2 photon prismaPath
hasn't been any help:
// output of a console.log(ctx.photon) in my nexus resolver
ctx.photon <ref *1> Photon {
engine: NodeEngine {
exiting: false,
managementApiEnabled: false,
ready: false,
stderrLogs: '',
stdoutLogs: '',
fail: [AsyncFunction (anonymous)],
cwd: '/api/prisma',
debug: false,
datamodelPath: '/api/node_modules/@prisma/photon/schema.prisma',
prismaPath: undefined, <---- !!!!!!!!!!!
generator: {
name: 'photon',
provider: 'photonjs',
output: '/api/node_modules/@prisma/photon',
binaryTargets: [],
config: {}
},
...
I'm following this example:
https://github.com/prisma/prisma-examples/blob/prisma2/typescript/graphql-apollo-server/src/schema.ts
https://github.com/prisma/prisma-examples/blob/prisma2/typescript/graphql-apollo-server/src/context.ts
I have re-initialized prisma2, deployed a fresh DB, and regenerated my data and clients plenty of times. I can seed the DB just fine, I can navigate the data fine using the Prisma Explorer, but my GraphQL queries always get the Invalid photon.() invocation
.
Happy to share more code if it helps 👍Thiago Camargo
12/15/2019, 9:19 PMCigoler
12/16/2019, 9:54 AMLukas Greb
12/16/2019, 6:53 PMconst where = args.filter ? {
OR: [
{ description_contains: args.filter },
{ url_contains: args.filter },
], } : {};
I used a local Database instead of the demo server (but I also just tried the demo server to make sure that's not causing the problem) and when running "prisma deploy" it complains that:
The field postedBy must provide a relation link mode. Either specify it on this field or the opposite field. Valid values are: @relation(link: INLINE)
plus a few other fields with the same problem. And even though those are easily solved by adding @relation(link: INLINE) to the appropiate spots, why do I need to do that anyway? It feels like when the project was created it worked without that, but why not anymore? When setting this up, the packages are installed with the intented version, so I'm completely lost whats wrong here...
It's making me furious when basic stuff like this doesn't work -_-
I hope someone can help me with this...Garrett Kelley
12/16/2019, 8:17 PMMuhaki
12/17/2019, 9:12 AM