Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tabtab feature not working #441

Closed
Physium opened this issue May 21, 2016 · 24 comments
Closed

tabtab feature not working #441

Physium opened this issue May 21, 2016 · 24 comments

Comments

@Physium
Copy link

Physium commented May 21, 2016

tabtab feature does not seems to be working.

After executing yo seems to only provide me folder options. Is the feature not working as intended?

@mklabs
Copy link
Contributor

mklabs commented May 21, 2016

What is your shell setup / operating system ?

With as little information, it is very difficult for me to see what is going on. There are known issues with zsh / bash I'm currently working on: mklabs/tabtab#21

That being said, thank you for the feedback.

@Walraz
Copy link

Walraz commented May 21, 2016

also same problem with tabtab

`
/Users/Rasmus/.nvm/versions/node/v6.2.0/lib/node_modules/yo/lib/cli.js:18
var tabtab = new (require('tabtab').Commands.default)({
^

TypeError: require(...).Commands.default is not a constructor
at Object. (/Users/Rasmus/.nvm/versions/node/v6.2.0/lib/node_modules/yo/lib/cli.js:18:14)
at Module._compile (module.js:541:32)
at Object.Module._extensions..js (module.js:550:10)
at Module.load (module.js:458:32)
at tryModuleLoad (module.js:417:12)
at Function.Module._load (module.js:409:3)
at Function.Module.runMain (module.js:575:10)
at startup (node.js:160:18)
at node.js:449:3
`

The problem is in both zsh and bash on osx

@devmanny
Copy link

devmanny commented May 21, 2016

same problem here when I run yo

/usr/local/lib/node_modules/yo/lib/cli.js:18
var tabtab = new (require('tabtab').Commands.default)({
             ^

TypeError: require(...).Commands.default is not a function
    at Object.<anonymous> (/usr/local/lib/node_modules/yo/lib/cli.js:18:14)
    at Module._compile (module.js:409:26)
    at Object.Module._extensions..js (module.js:416:10)
    at Module.load (module.js:343:32)
    at Function.Module._load (module.js:300:12)
    at Function.Module.runMain (module.js:441:10)
    at startup (node.js:139:18)
    at node.js:968:3

$ node -v
v4.4.4

$ npm -v
3.9.2

PD: I'm using zsh and OSX 10.11.4

@abdulapopoola
Copy link

abdulapopoola commented May 21, 2016

Also have the same issue on Ubuntu bash

npm @3.8.9
node @6.2.0

@eads
Copy link

eads commented May 21, 2016

Same problem, OS X / bash

@adrianeguez
Copy link

Hello guys, same problem here! I am using :
windows 8,
npm version 3.9.2 and
node version 4.4.4 and
also with the latest node version now 6.2.0
only using yo in the cmd triggers the error:

C:\Users\Adrian\AppData\Roaming\npm\node_modules\yo\lib\cli.js:18
var tabtab = new (require('tabtab').Commands.default)({
             ^

TypeError: require(...).Commands.default is not a function
    at Object.<anonymous> (C:\Users\Adrian\AppData\Roaming\npm\node_modules\yo\l
ib\cli.js:18:14)
    at Module._compile (module.js:409:26)
    at Object.Module._extensions..js (module.js:416:10)
    at Module.load (module.js:343:32)
    at Function.Module._load (module.js:300:12)
    at Function.Module.runMain (module.js:441:10)
    at startup (node.js:139:18)
    at node.js:968:3

@mklabs
Copy link
Contributor

mklabs commented May 21, 2016

Thx guys

@SBoudrias this is due to a new version of tabtab where I added the babel plugin for this, something we discussed here: #436 (comment)

#442 should fix it

We should probably lock the version of tabtab up to the minor version, I wasn't expecting yeoman to automatically upgrade to tabtab v1.4, that was something I planned to do in #442

@adrianeguez
Copy link

I did not understand #442 😢 what should I do? unninstall tab tab and reinstall globally with another version?

@mklabs
Copy link
Contributor

mklabs commented May 21, 2016

I'll try to unpublish tabtab v1.4 and see if it fixes the issue here.

The problem here is that you most likely have the latest version of tabtab installed with yo, ([email protected]) which introduces a change in how babel compiles the generated code. Yo in his current state is compatible with 1.3.x

It goes in pair with #442 which is not merged yet.

@mklabs
Copy link
Contributor

mklabs commented May 21, 2016

Just unpublished, it should fix your issue with yo. Can anyone confirm yo installs fine now ? It did on my local machine.

Sorry, all my fault. Unintended side effect of publishing a new version of tabtab in order to work on #442

@MichaelPruefer
Copy link

Great!
Works now on Win 10, npm 3.9.2, node 4.4.4

@eads
Copy link

eads commented May 21, 2016

@mklabs working now on OS X / bash / npm 3.9.2 / node 4.2.1

@adrianeguez
Copy link

It fixed it on my local yo,
changed package.json

...
    "tabtab": "1.3.0",
...

Thanks!

@mklabs
Copy link
Contributor

mklabs commented May 21, 2016

Great, thanks a lot.

@Physium I don't think it was related to your original issue, feel free to keep this issue open and provide more feedback, that being said #442 should improve zsh / bash completions a lot.

@Walraz
Copy link

Walraz commented May 21, 2016

@mklabs works fine now with reiinstall of yo! zsh on OSX

@mklabs
Copy link
Contributor

mklabs commented May 21, 2016

@Walraz 👍

@Physium
Copy link
Author

Physium commented May 23, 2016

@mklabs

Just unpublished, it should fix your issue with yo. Can anyone confirm yo installs fine now ? It did on my local machine.

Hi! Sry for going missing throughout the weekend after posting this issue. I just did a reinstall and notice that it didnt prompt me about the yo-complete feature. I'm assuming that this means that the yo-complete tabtab feature has been remove from for now till #442 has been merge?

@mklabs
Copy link
Contributor

mklabs commented May 23, 2016

Hi @Physium no worries.

Let's continue this discussion on tabtab repo. Yes, the completion feature doesn't prompt on install anymore, you can get these prompts with yo completion right now. #442 will change that (not merged yet)

@davidsidlinger
Copy link

I am seeing this come up on macOS Sierra. At the moment, I am working around the problem by installing an older version of the package. Sad face.

/usr/local/lib/node_modules/yo/lib/cli.js:18
var tabtab = new (require('tabtab').Commands.default)({
             ^

TypeError: require(...).Commands.default is not a constructor
    at Object.<anonymous> (/usr/local/lib/node_modules/yo/lib/cli.js:18:14)
    at Module._compile (module.js:556:32)
    at Object.Module._extensions..js (module.js:565:10)
    at Module.load (module.js:473:32)
    at tryModuleLoad (module.js:432:12)
    at Function.Module._load (module.js:424:3)
    at Module.runMain (module.js:590:10)
    at run (bootstrap_node.js:394:7)
    at startup (bootstrap_node.js:149:9)
    at bootstrap_node.js:509:3

Output of npm install -g yo:

npm WARN deprecated [email protected]: this package has been reintegrated into npm and is now out of date with respect to npm
/usr/local/bin/yo -> /usr/local/lib/node_modules/yo/lib/cli.js
/usr/local/bin/yo-complete -> /usr/local/lib/node_modules/yo/lib/completion/index.js

> [email protected] postinstall /usr/local/lib/node_modules/yo/node_modules/spawn-sync
> node postinstall


> [email protected] postinstall /usr/local/lib/node_modules/yo
> yodoctor


Yeoman Doctor
Running sanity checks on your system

✔ Global configuration file is valid
✔ NODE_PATH matches the npm root
✔ Node.js version
✔ No .bowerrc file in home directory
✔ No .yo-rc.json file in home directory
✔ npm version

Everything looks all right!

Output of npm list -g tabtab:

/usr/local/lib
└─┬ [email protected]
  └── [email protected]

node: v6.7.0
npm: v3.10.8
fish shell: 2.3.1
macOS 10.12 (16A323)

@mklabs
Copy link
Contributor

mklabs commented Sep 30, 2016

@davidsidlinger I published a new version of tabtab today but didn't remembered the integration in yo. I unpublished it, it should be okay now.

@bike2live
Copy link

I get the same error as @davidsidlinger.

node: 5.9.1
npm: 3.8.9
macOS 10.12
bash 3.2

Is the only work-around manually setting the version of tabtab to 1.3.x?

@mklabs
Copy link
Contributor

mklabs commented Sep 30, 2016

Hi @bike2live, if you try to uninstall yo and reinstall it should install tabtab in its latest 1.x version which is now 1.3.2 now that I unpublished 1.4.3

@bike2live
Copy link

That appears to have solved the issue. Thanks for the quick response.

@davidsidlinger
Copy link

Echoing @bike2live. I am up and running on [email protected]. Thanks for your help, @mklabs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests