P
Prisma3w ago
Justin

The requested module '@prisma/generator-helper' does not provide an export named 'generatorHandler'

Hi there! I am trying to write a custom generator but cannot get past the error above. It looks like prisma.schema is properly configured to call the generator but once inside the file where it is defined, an immediate The requested module '@prisma/generator-helper' does not provide an export named 'generatorHandler' is thrown. VSCode takes me to the type declaration for generatorHandler when ctrl+clicking the import so VSCode at least recognizes it. It looks like the @prisma/generator-helper package is deprecated in favor of @prisma/generator but examples using the new package appear to be non-existent . I have tried following along with the prisma-client-js code to replicate it but it looks pretty involved and I cannot seem to work it down to a minimum workable solution. Thanks in advance for any help!
2 Replies
Prisma AI Help
You decided to hold for human wisdom. We'll chime in soon! Meanwhile, #ask-ai is there if you need a quick second opinion.
Nurul
Nurul2w ago
Hey Justin! Do you mind creating a GitHub Issue so that our Prisma ORM team can help investigate. They have the most up to date context about internal prisma packages like @prisma/generator https://github.com/prisma/prisma/issues/
GitHub
Issues · prisma/prisma
Next-generation ORM for Node.js & TypeScript | PostgreSQL, MySQL, MariaDB, SQL Server, SQLite, MongoDB and CockroachDB - Issues · prisma/prisma

Did you find this page helpful?