#' @prisma/client did not initialize yet.' with Docker

1 messages · Page 1 of 1 (latest)

vague zinc
#

I have a problem with prisma generate command. Is there any way to fix it? PS. I tried typing 'prisma generate' at terminal

#

btw, typo at docker-compose is already fixed(

short zealot
#

when you run docker compose for the first time, and you aren't directly copying your node_modules the types that prisma uses don't exist yet

#

you need to create a command to run prisma generate

vague zinc
short zealot
#

you can either do it in the docker compose or you can do it in the with the command block

#

I forgot the cmd, but it's one to do multiple commands

#

so you can do somehting like npx prisma generate & npm run start:dev

#

I'm not entirely sure if you can do it in the docker file

#

does what I said make sense?

vague zinc
short zealot
#

depending on if you're on windows or macos, you would use bash or sh respectively

vague zinc
#

I guess it works! Thank you🤍

short zealot
#

if you're still a little confused I'd be happy to explain haha

vague zinc
short zealot
#

can I get a picture of the issue? or can you just paste the error in here?

short zealot
#

not sure if the bcrypt module comes with type definitions, but did you install those?

vague zinc
#

can the problem appear because of the Docker?

short zealot
#

I believe so, I can't remember why

#

but I previously used to use bcrypt, but I changed to using bcryptjs instead for some reason taht I can't remember anymore

vague zinc
#

should I try?

short zealot
#

try installing bcryptjs and @types/bcryptjs

vague zinc
#

ok. one sec

short zealot
#

uhhh if you'd like

#

the methods are slightly different, but should also get the job done

vague zinc
#

same thing(

#

he doesn't see npm packages I install for some reason

vague zinc
short zealot
#

it could be... I've never put a volume on an API before, so I'm not entirely sure if that's the issue

#

can you provide a minium reproduction of this?

short zealot
#

like a the bare necessities to replicate the repository