I also had this problem. I also use nvm for node version control.
In my case, some combination of npm dedupe -g , npm update -g yo , npm uninstall -g yo and npm install -g yo did the trick. I also reinstall npm link from my generator, as it is a local generator. I think if it is a generator installed with npm, npm uninstall -g <generator-name> followed by `npm install -g, the same target will be used.
At some point during all this, the generator started working again, but I did not notice exactly when, because I ran the generator as part of my unit tests.
In the end, I realized that the generator worked when I ran it from the command line, but not when I ran it from my test files.
At that moment, updating the yeoman testing assistants ( npm update yeoman-test ) from 1.1.0 to 1.4.0 did the trick.
source share