dustinspecker / generator-ng-poly

Yeoman generator for modular AngularJS apps with Gulp and optional Polymer support
MIT License
237 stars 50 forks source link

Getting TypeError: _.invokeMap is not a function when trying to generate services, modules... #348

Open jeffarese opened 8 years ago

jeffarese commented 8 years ago

I'm working on a long-time project using this generator, and lately I'm getting this error when trying to create a new service/module/directive... etc:


_.invokeMap(this._composedWith, 'run');
    ^

TypeError: _.invokeMap is not a function
    at child.run (/home/jeff/workspace/jarvis/jarvis/node_modules/yeoman-generator/lib/base.js:496:5)
    at Environment.run (/home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/node_modules/yeoman-environment/lib/environment.js:377:20)
    at /home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/lib/cli.js:140:11
    at Array.forEach (native)
    at /home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/lib/cli.js:139:9
    at Environment.resolver.lookup (/home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/node_modules/yeoman-environment/lib/resolver.js:50:12)
    at init (/home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/lib/cli.js:115:7)
    at pre (/home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/lib/cli.js:73:3)
    at Object.<anonymous> (/home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/lib/cli.js:194:3)

I have NVM installed and I tried with different node versions (5.0.0, 6.5.0) so I don't know what happens.

I've tried in another different computers with fresh node and yeoman installs and the same error pops up.

Any ideas?

dustinspecker commented 8 years ago

Hmm. Does using yo ng-poly:service a --module=home, etc. work? I'll try to look into this tonight.

jeffarese commented 8 years ago

Hi @dustinspecker. No, I get the same error... Right now I'm trying with Node 6.5.0 and npm 3.10.3.

jeffarese commented 7 years ago

Hi again @dustinspecker, have you seen anything new about this?

dustinspecker commented 7 years ago

Really sorry, I forgot about this.

I'm unable to reproduce this so far. During the initial project creation are there any Bower or npm errors?

I tried with Node 6.5.0 (with nvm), npm 3.10.3, yo 1.8.5, and ng-poly 13.0.0.

EDIT: Make sure yo is up-to-date. I believe there were some big changes with it when yeoman updated a bit ago.

dustinspecker commented 7 years ago

Have you been able to try anything further?