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

cannot start terminal #362

Closed
ziong opened this issue Oct 20, 2016 · 25 comments
Closed

cannot start terminal #362

ziong opened this issue Oct 20, 2016 · 25 comments

Comments

@ziong
Copy link

ziong commented Oct 20, 2016

The terminal cannot startup, black screen.

Seems the pty.js cannot load the ia32.node due to version issue.
I am using win10, atom1.11.2.

task.coffee:86 Module version mismatch. Expected 47, got 46. Error: Module version mismatch. Expected 47, got 46.
    at Error (native)
    at process.module.(anonymous function) [as dlopen] (ELECTRON_ASAR.js:158:20)
    at Object.Module._extensions..node (module.js:440:18)
    at Object.module.(anonymous function) [as .node] (ELECTRON_ASAR.js:158:20)
    at Module.load (module.js:357:32)
    at Function.Module._load (module.js:314:12)
    at Module.require (module.js:367:17)
    at require (internal/module.js:16:19)
    at Object.<anonymous> (C:\Users\User\.atom\packages\terminal-plus\node_modules\pty.js\lib\pty.js:17:9)
    at Module._compile (module.js:413:34)
    at Object.defineProperty.value [as .js] 

Screen capture as below:
image

also find the builderror.log, details:

gyp ERR! build error 
gyp ERR! stack Error: `C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onExit (C:\Users\User\AppData\Local\atom\app-1.11.2\resources\app\apm\node_modules\node-gyp\lib\build.js:276:23)
gyp ERR! stack     at emitTwo (events.js:87:13)
gyp ERR! stack     at ChildProcess.emit (events.js:172:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Windows_NT 10.0.14393
gyp ERR! command "C:\\Users\\User\\AppData\\Local\\atom\\app-1.11.2\\resources\\app\\apm\\bin\\node.exe" "C:\\Users\\User\\AppData\\Local\\atom\\app-1.11.2\\resources\\app\\apm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\Users\User\AppData\Local\Temp\apm-install-dir-116920-12404-1xr1xr6\node_modules\terminal-plus\node_modules\pty.js
gyp ERR! node -v v4.4.5
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok 

At a guess, this is a dupe of #353

@championswimmer
Copy link

Same here.

@tarkanlar
Copy link

+1 Same here

@jbcl-io
Copy link

jbcl-io commented Oct 21, 2016

+1

@thongdong7
Copy link

Same issue with Ubuntu 16.04, Atom 1.11.2

@sir-marc
Copy link

same here: windows 10

@LarsKumbier
Copy link

I was able to fix this by a dependency-update (see above) for Ubuntu 16.04.
Could someone check it on a windows-10-box for confirmation and comment in the merge-request?

@ccaspers
Copy link

Same issue with Ubuntu 16.10 and Atom 1.11.2. The fix from @LarsKumbier works for me.

@ziong
Copy link
Author

ziong commented Oct 24, 2016

sorry that, can tell me how to update pty.js to v0.3.1?
I try to run "npm install", but got this error:
image

@LarsKumbier
Copy link

LarsKumbier commented Oct 24, 2016

@ziong follow these steps:

  1. Remove / uninstall terminal-plus if not already done (thx @spdaly)
  2. Clone my repository linked above
  3. Run npm i to install all dependencies
  4. Run apm link to link the current directory as a plugin for atom
  5. Run apm rebuild to rebuild all dependencies
  6. Start Atom and check

@ziong
Copy link
Author

ziong commented Oct 24, 2016

thanks for your advice @LarsKumbier
however, no luck.
seems that the deps\winpty is empty when clone the repository, which leads error on "npm i"

any idea?

@spdaly
Copy link

spdaly commented Oct 24, 2016

@LarsKumbier Thanks for the comment. Works for me!

I would add one step to your list. Uninstall terminal-plus first. The apm link will fail otherwise.

@LarsKumbier
Copy link

@ziong could you specify? Best is a log dump of the start until the error message.

@ziong
Copy link
Author

ziong commented Oct 26, 2016

@LarsKumbier After a long journey, finally it works.
First problem, I was stuck on compiling winpty on Windows 10, many issues (e.g. rprichard/winpty#87)
the repository linked of pty.js won't work.
After tried different forks, https://github.com/Tyriar/pty.js lastly works .
Second, apm link won't work, I don't know why. The link is created, but it haven't been invoked.

So, here comes my findings:

Prerequisites:
node (5.x is not work, i use 7.0.0, now)
Visual Studio 2015 Update 3 (i use community version)

Steps:

  1. install terminal-plus (big difference from @spdaly's finding)
  2. close atom
  3. cd to terminal-plus\node_modules
  4. remove the pty.js in terminal-plus\node_modules
  5. git clone https://github.com/Tyriar/pty.js.git
  6. cd pty.js
  7. npm i
  8. cd ../..
  9. apm rebuild
  10. start atom

Hope this help.
Thanks @LarsKumbier

@kabobbob
Copy link

@ziong I was having the same issue on macOS Sierra. Tried your steps and it worked for me.

@ziong
Copy link
Author

ziong commented Oct 26, 2016

I think we have a workaround now.
Hope it will be fixed soon.

@ziong ziong closed this as completed Oct 26, 2016
@mjarraya
Copy link

@ziong's solution worked for me as well.
Mac OS X

@alexrussell
Copy link

@LarsKumbier your method of cloning your version, linking it and then doing a rebuild did not work for me:

alexrussell at Alexs-MacBook in ~/projects/atom/terminal-plus on master
❯ npm i

> pty.js@0.3.1 install /Users/alexrussell/projects/atom/terminal-plus/node_modules/pty.js
> node-gyp rebuild

  CXX(target) Release/obj.target/pty/src/unix/pty.o
  SOLINK_MODULE(target) Release/pty.node
terminal-plus@0.14.5 /Users/alexrussell/projects/atom/terminal-plus
├─┬ atom-space-pen-views@2.2.0
│ ├── fuzzaldrin@2.1.0
│ └─┬ space-pen@5.1.2
│   ├─┬ grim@1.5.0
│   │ └─┬ emissary@1.3.3
│   │   ├─┬ es6-weak-map@0.1.4
│   │   │ ├── d@0.1.1
│   │   │ ├─┬ es5-ext@0.10.12
│   │   │ │ ├── es6-iterator@2.0.0
│   │   │ │ └── es6-symbol@3.1.0
│   │   │ ├── es6-iterator@0.1.3
│   │   │ └── es6-symbol@2.0.1
│   │   ├── mixto@1.0.0
│   │   └── property-accessors@1.1.3
│   ├── jquery@2.1.4
│   └─┬ underscore-plus@1.6.6
│     └── underscore@1.6.0
├─┬ pty.js@0.3.1  (git+https://github.com/jeremyramin/pty.js.git#fe63a412574f45ee6bb6d8fab4a5c102107b5201)
│ ├── extend@1.2.1
│ └── nan@2.3.5
├── term.js@0.0.7  (git+https://github.com/jeremyramin/term.js.git#de1635fc2695e7d8165012d3b1d007d7ce60eea2)
└── underscore@1.8.3


alexrussell at Alexs-MacBook in ~/projects/atom/terminal-plus on master
❯ apm-beta link
/Users/alexrussell/.atom/packages/terminal-plus -> /Users/alexrussell/projects/atom/terminal-plus

alexrussell at Alexs-MacBook in ~/projects/atom/terminal-plus on master
❯ apm-beta rebuild
Rebuilding modules ✗
make: *** No rule to make target `../../../../../../../../Applications/Atom', needed by `Makefile'.  Stop.
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/Applications/Atom Beta.app/Contents/Resources/app/apm/node_modules/node-gyp/lib/build.js:276:23)
gyp ERR! stack     at emitTwo (events.js:87:13)
gyp ERR! stack     at ChildProcess.emit (events.js:172:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Darwin 15.6.0
gyp ERR! command "/Applications/Atom Beta.app/Contents/Resources/app/apm/bin/node" "/Applications/Atom Beta.app/Contents/Resources/app/apm/node_modules/.bin/node-gyp" "rebuild"
gyp ERR! cwd /Users/alexrussell/projects/atom/terminal-plus/node_modules/pty.js
gyp ERR! node -v v4.4.5
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

npm ERR! Darwin 15.6.0
npm ERR! argv "/Applications/Atom Beta.app/Contents/Resources/app/apm/bin/node" "/Applications/Atom Beta.app/Contents/Resources/app/apm/node_modules/npm/bin/npm-cli.js" "--globalconfig" "/Users/alexrussell/.atom/.apm/.apmrc" "--userconfig" "/Users/alexrussell/.atom/.apmrc" "rebuild" "--runtime=electron" "--target=1.3.6" "--arch=x64"
npm ERR! node v4.4.5
npm ERR! npm  v3.10.5
npm ERR! code ELIFECYCLE
npm ERR! pty.js@0.3.1 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the pty.js@0.3.1 install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the pty.js package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs pty.js
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls pty.js
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /Users/alexrussell/projects/atom/terminal-plus/npm-debug.log

It may well be that I use Atom Beta, and for some reason the node-gyp build assumes Atom, see the error: make: *** No rule to make target ../../../../../../../../Applications/Atom', needed by Makefile'. Stop.

I might try @ziong's method in a bit, though it'd be handy if these packages would just work :)

@proteo
Copy link

proteo commented Oct 30, 2016

@ziong method worked for me too, it works even with Atom 1.12.0-beta5!!

MacOS X 10.11.6

@cgrs
Copy link

cgrs commented Nov 1, 2016

@LarsKumbier Thanks for the fix!
I think it'd be easier to install it by using the github shorthand on apm:
apm install LarsKumbier/terminal-plus

@LarsKumbier
Copy link

@cgrs I didn't know that that was a possibility - awesome tipp!

@newelement
Copy link

@ziong method worked for me too. Big thanks!

@sir-marc
Copy link

sir-marc commented Nov 2, 2016

@cgrs does not work for me:

failed
Request for package information failed: Not Found

@cgrs
Copy link

cgrs commented Nov 2, 2016

@sir-marc well, the repo is still online. if you didn't manage to make it work, you can also try @LarsKumbier 's 'manual' method posted above, or you can use other options available on the commandline help of apm.

@tspeigner
Copy link

@ziong that worked for me too. thanks for the help on that.

@syky27
Copy link

syky27 commented Nov 3, 2016

@ziong Thanks mate

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