macstr1k3r / trpc-nestjs-adapter

An adapter, allowing you to use TRPC inside of Nest.JS
158 stars 14 forks source link

Infinite loading when Prisma module injected into resolved dependency #8

Open jdpt0 opened 10 months ago

jdpt0 commented 10 months ago

Hi, thanks for the great adapter!

I'm trying it out but having issues resolving services that have a Prisma service injected into them (most of the services in the application), which is very similar to the example in the Nest docs: https://docs.nestjs.com/recipes/prisma#use-prisma-client-in-your-nestjs-services. I just get an infinite loading spinner when I try to access any of the trpc endpoints. It seems to work when I use a service in tRPC that doesn't have any injected dependencies.

Does anyone have any ideas why this isn't resolving? Is there any more information I can provide to help debug this? Would love to be able to use this properly!

EDIT: Tried nestjs-prisma too and this exhibits the same behavior. NodeJS ran out of memory after hitting the tRPC endpoint.

medv commented 9 months ago

You might need to provide a reproduction, my own PrismaModule as well as a nestjs-prisma module work without this issue.