mikro-orm: 4.0.0-rc.3 and 4.0.0-rc.4 with escaya break projects that depend on acorn
Describe the bug After updating from 4.0.0-rc.2 to rc.3 and rc.4, dependencies of my project which use acorn, such as @nestjs/graphql, stop working. I narrowed it down to a potential conflict between escaya and one of the acorn packages, but because I am not familiar with the internals, I do not yet know the specific cause. I think potentially escaya might be making a declaration that is overwriting something that acorn also uses.
Stack trace
GraphQLError [Object]: Input Object type AccessTokenCreateInput must define one or more fields.
at SchemaValidationContext.reportError (/example/node_modules/graphql/type/validate.js:88:19)
at validateInputFields (/example/node_modules/graphql/type/validate.js:420:13)
at validateTypes (/example/node_modules/graphql/type/validate.js:218:7)
at validateSchema (/example/node_modules/graphql/type/validate.js:54:3)
at graphqlImpl (/example/node_modules/graphql/graphql.js:79:62)
at /example/node_modules/graphql/graphql.js:28:59
at new Promise (<anonymous>)
at Object.graphql (/example/node_modules/graphql/graphql.js:26:10)
at GraphQLSchemaFactory.<anonymous> (/example/node_modules/@nestjs/graphql/dist/schema-builder/graphql-schema.factory.js:49:52)
at Generator.next (<anonymous>)
(node:65595) UnhandledPromiseRejectionWarning: Error: Schema generation error (code-first approach)
at GraphQLSchemaFactory.<anonymous> (/example/node_modules/@nestjs/graphql/dist/schema-builder/graphql-schema.factory.js:51:27)
at Generator.next (<anonymous>)
at fulfilled (/example/node_modules/@nestjs/graphql/node_modules/tslib/tslib.js:111:62)
at processTicksAndRejections (internal/process/task_queues.js:93:5)
Versions
| Dependency | Version |
|---|---|
| node | v14.8.0 |
| typescript | 4.0.2 |
| mikro-orm | 4.0.0-rc.4 |
| your-driver | postgresql |
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 15 (6 by maintainers)
I am happy to report that as of v4.0.3 I no longer experience this error. I am not sure what specific changes in my project or its dependencies in the past 3 weeks fixed the issue, but I would like to thank everyone for their input and help!
@pigulla hopefully 4.0.3 works for you as well!