Dependency injection errors not informative
See original GitHub issueI’m submitting a…
[x] Regression
[ ] Bug report
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead post your question on Stack Overflow.
Current behavior
DI errors don’t have the service name and/or the failed dependency anymore:
1: node::Abort() [/Users/me/.nvm/versions/node/v8.11.3/bin/node]
2: node::Chdir(v8::FunctionCallbackInfo<v8::Value> const&) [/Users/me/.nvm/versions/node/v8.11.3/bin/node]
3: v8::internal::FunctionCallbackArguments::Call(void (*)(v8::FunctionCallbackInfo<v8::Value> const&)) [/Users/me/.nvm/versions/node/v8.11.3/bin/node]
4: v8::internal::MaybeHandle<v8::internal::Object> v8::internal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::Isolate*, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::Handle<v8::internal::Object>, v8::internal::BuiltinArguments) [/Users/me/.nvm/versions/node/v8.11.3/bin/node]
5: v8::internal::Builtin_Impl_HandleApiCall(v8::internal::BuiltinArguments, v8::internal::Isolate*) [/Users/me/.nvm/versions/node/v8.11.3/bin/node]
6: 0x285c1f0842fd
Expected behavior
Injection errors should have informative error messages about the failed property target, etc as before 5.3.0.
Minimal reproduction of the problem with instructions
package.json:
"@nestjs/common": "^5.3.2",
"@nestjs/core": "^5.3.2",
"@nestjs/graphql": "^5.1.1",
"@nestjs/jwt": "^0.1.3",
"@nestjs/passport": "^5.0.1",
"@nestjs/typeorm": "^5.2.0",
"@nestjs/websockets": "^5.3.1",
What is the motivation / use case for changing the behavior?
Environment
Nest version: 5.3.2
For Tooling issues:
- Node version: 8.11.3
- Platform: macos 10.13.3
Others:
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
java - Dependency Injection Does not work in Models or Tests ...
I am trying to write some unit tests for my Play Framework 2.4.6 application. I need WS for my purposes testing. However, when...
Read more >Troubleshooting contexts and dependency injection - IBM
Use this task to troubleshoot errors related to Contexts and Dependency Injection (CDI) for the Java Platform, Enterprise Edition (Java EE) ...
Read more >ASP.NET Core Dependency Injection Deep Dive
I am trying to troubleshoot a "cannot resolve scoped service from root provider" error in my application. There is very little on this...
Read more >Functional approaches to dependency injection
For people who are learning functional programming techniques, one of the more common questions is: “how do you do dependency injection?
Read more >Java Annotation: Dependency Injection and Beyond
However this information with an annotation does not change the semantics of a program. There are many uses of Java annotations during both...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Is there code that can be reproduced? Or full logs?
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.