bug? (core) Injector: Object prototype may only be an Object or null: undefined
See original GitHub issue╭─cojack@cojack-laptop ~/Projects/private/i-know-nest ‹v8.5.0› ‹master›
╰─$ npm start 10:22:21
> i-know-nest@2.0.0 start /home/cojack/Projects/private/i-know-nest
> node node_modules/.bin/ts-node $NODE_DEBUG_OPTION src/index.ts
[Nest] 21964 - 2017-11-4 10:22:27 [NestFactory] Starting Nest application...
[Nest] 21964 - 2017-11-4 10:22:27 [ExceptionHandler] Object prototype may only be an Object or null: undefined
TypeError: Object prototype may only be an Object or null: undefined
at Function.create (<anonymous>)
at Injector.loadPrototypeOfInstance (/home/cojack/Projects/private/i-know-nest/node_modules/@nestjs/core/injector/injector.js:50:89)
at module.components.forEach (/home/cojack/Projects/private/i-know-nest/node_modules/@nestjs/core/injector/instance-loader.js:47:27)
at Map.forEach (native)
at InstanceLoader.createPrototypesOfComponents (/home/cojack/Projects/private/i-know-nest/node_modules/@nestjs/core/injector/instance-loader.js:46:27)
at modules.forEach (/home/cojack/Projects/private/i-know-nest/node_modules/@nestjs/core/injector/instance-loader.js:29:18)
at Map.forEach (native)
at InstanceLoader.createPrototypes (/home/cojack/Projects/private/i-know-nest/node_modules/@nestjs/core/injector/instance-loader.js:28:17)
at InstanceLoader.<anonymous> (/home/cojack/Projects/private/i-know-nest/node_modules/@nestjs/core/injector/instance-loader.js:23:18)
at Generator.next (<anonymous>)
1: node::Abort() [/home/cojack/.nvm/versions/node/v8.5.0/bin/node]
2: 0x13576f9 [/home/cojack/.nvm/versions/node/v8.5.0/bin/node]
3: v8::internal::FunctionCallbackArguments::Call(void (*)(v8::FunctionCallbackInfo<v8::Value> const&)) [/home/cojack/.nvm/versions/node/v8.5.0/bin/node]
4: 0xc1365a [/home/cojack/.nvm/versions/node/v8.5.0/bin/node]
5: v8::internal::Builtin_HandleApiCall(int, v8::internal::Object**, v8::internal::Isolate*) [/home/cojack/.nvm/versions/node/v8.5.0/bin/node]
6: 0x14ce1ea046fd
Aborted (core dumped)
npm ERR! code ELIFECYCLE
npm ERR! errno 134
npm ERR! i-know-nest@2.0.0 start: `node node_modules/.bin/ts-node $NODE_DEBUG_OPTION src/index.ts`
npm ERR! Exit status 134
npm ERR!
npm ERR! Failed at the i-know-nest@2.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/cojack/.npm/_logs/2017-11-04T09_22_27_569Z-debug.log
Output from logs:
╭─cojack@cojack-laptop ~/Projects/private/i-know-nest ‹v8.5.0› ‹master›
╰─[134 ↵]─$ cat /home/cojack/.npm/_logs/2017-11-04T09_22_27_569Z-debug.log 10:22:27
0 info it worked if it ends with ok
1 verbose cli [ '/home/cojack/.nvm/versions/node/v8.5.0/bin/node',
1 verbose cli '/home/cojack/.nvm/versions/node/v8.5.0/bin/npm',
1 verbose cli 'start' ]
2 info using npm@5.4.2
3 info using node@v8.5.0
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle i-know-nest@2.0.0~prestart: i-know-nest@2.0.0
6 info lifecycle i-know-nest@2.0.0~start: i-know-nest@2.0.0
7 verbose lifecycle i-know-nest@2.0.0~start: unsafe-perm in lifecycle true
8 verbose lifecycle i-know-nest@2.0.0~start: PATH: /home/cojack/.nvm/versions/node/v8.5.0/lib/node_modules/npm/bin/node-gyp-bin:/home/cojack/Projects/private/i-know-nest/node_modules/.bin:/home/cojack/.nvm/versions/node/v8.5.0/bin:/home/cojack/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
9 verbose lifecycle i-know-nest@2.0.0~start: CWD: /home/cojack/Projects/private/i-know-nest
10 silly lifecycle i-know-nest@2.0.0~start: Args: [ '-c',
10 silly lifecycle 'node node_modules/.bin/ts-node $NODE_DEBUG_OPTION src/index.ts' ]
11 silly lifecycle i-know-nest@2.0.0~start: Returned: code: 134 signal: null
12 info lifecycle i-know-nest@2.0.0~start: Failed to exec start script
13 verbose stack Error: i-know-nest@2.0.0 start: `node node_modules/.bin/ts-node $NODE_DEBUG_OPTION src/index.ts`
13 verbose stack Exit status 134
13 verbose stack at EventEmitter.<anonymous> (/home/cojack/.nvm/versions/node/v8.5.0/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:280:16)
13 verbose stack at emitTwo (events.js:125:13)
13 verbose stack at EventEmitter.emit (events.js:213:7)
13 verbose stack at ChildProcess.<anonymous> (/home/cojack/.nvm/versions/node/v8.5.0/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at emitTwo (events.js:125:13)
13 verbose stack at ChildProcess.emit (events.js:213:7)
13 verbose stack at maybeClose (internal/child_process.js:927:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
14 verbose pkgid i-know-nest@2.0.0
15 verbose cwd /home/cojack/Projects/private/i-know-nest
16 verbose Linux 4.13.0-16-lowlatency
17 verbose argv "/home/cojack/.nvm/versions/node/v8.5.0/bin/node" "/home/cojack/.nvm/versions/node/v8.5.0/bin/npm" "start"
18 verbose node v8.5.0
19 verbose npm v5.4.2
20 error code ELIFECYCLE
21 error errno 134
22 error i-know-nest@2.0.0 start: `node node_modules/.bin/ts-node $NODE_DEBUG_OPTION src/index.ts`
22 error Exit status 134
23 error Failed at the i-know-nest@2.0.0 start script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 134, true ]
Code at repository: https://github.com/cojack/i-know-nest
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Object prototype may only be an Object or null: undefined
Lately, we're seeing errors popping up in our monitoring system with this error message Object prototype may only be an Object or null: ......
Read more >TypeError: Object prototype may only be an Object or null ...
I can't figure out which one was the problem or why the code that the error points to give wrong as it is...
Read more >The "Uncaught TypeError: Object prototype may only be an ...
The "Uncaught TypeError: Object prototype may only be an Object or null: undefined" error occurs while inserting DevExpress Reporting widgets ...
Read more >Object Prototype May Only Be An Object Or Null: Undefined
Object prototype may only be an Object or null: undefined TypeError: I wish to create one component that can be inherited and used...
Read more >TypeError: Object prototype may only be an Object or null: ...
I created new reactJs project to apply BPMN.IO I have this package.json file "dependencies": { "bpmn-font": "^0.10.0", "bpmn-js": "^7.4.0", ...
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
Ohh, I see already. In your
users.module.ts
you have:The
usersProviders
variable is an array. Use...usersProviders
instead. 🙂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.