facebookarchive / nuclide

An open IDE for web and native mobile development, built on top of Atom
https://nuclide.io
Other
7.79k stars 682 forks source link

unable to connect from client (osx) to server (raspberry pi) #1202

Open SuperCipher opened 7 years ago

SuperCipher commented 7 years ago

Issue and Steps to Reproduce

unable to connect from client to server

Expected Behavior

establish remote connection shown in atom client

Actual Behavior

error : The log file can be found at /tmp/nuclide-pi-logs/server-start/nuclide-2017-06-17T14:34:32.nohup.out.

log file on server:

/usr/local/lib/node_modules/nuclide/pkg/nuclide-server/lib/nuclide-main.js:20 const {DEV} = require('../../nuclide-node-transpiler/lib/env'); ^

SyntaxError: Unexpected token { at exports.runInThisContext (vm.js:53:16) at Module._compile (module.js:414:25) at Object.Module._extensions..js (module.js:442:10) at Module.load (module.js:356:32) at Function.Module._load (module.js:311:12) at Function.Module.runMain (module.js:467:10) at startup (node.js:134:18) at node.js:961:3

{"workspace": null, "success": true, "ca": "-----BEGIN CERTIFICATE-----\nMIICWDCCAcGgAwIBAgIJAL+DiJxb1gbPMA0GCSqGSIb3DQEBCwUAMEUxCzAJBgNV\nBAYTAkFVMRMwEQYDVQQIDApTb21lLVN0YXRlMSEwHwYDVQQKDBhJbnRlcm5ldCBX\naWRnaXRzIFB0eSBMdGQwHhcNMTcwNjE3MTQ1MjE5WhcNMTcwNzAxMTQ1MjE5WjBF\nMQswCQYDVQQGEwJBVTETMBEGA1UECAwKU29tZS1TdGF0ZTEhMB8GA1UECgwYSW50\nZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKB\ngQCjWo7dr4ZDiUmd8iVBFHyeHC+HWaOKVuQJQogZwMYqkSIxhYJKcRjVjMcnTmlF\ntn5Cr86xrAzUBqlsLF3PdUSpt9k07LkkDLeoFYwpjhAWJqN6RFevpS9Zg3kgwSWA\nUH1ctLB0rTC3CSzGongLHCKRUny2iNS9dOzHR+4TLj2D3QIDAQABo1AwTjAdBgNV\nHQ4EFgQUWS/TQ3l1gmdcw2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----\n", "version": "233", "key": "-----BEGIN RSA PRIVATE KEY-----\nMIICXAIBAAKBgQDWBQRzcRzuurXEprE9yYi8KDbK+ztS5yyAIi8Mb9y6lc9E3uBe\nRVjWmtCwAWFB4+9I8AH6jKhOzK4Ui9Zv/WwDbhnpzSDBD3qBms8T3ECGYz9LE8am\nk7X3qMQgvCHyVCRoujNlgoqzQeQke7Z7e81UpZ2nKA3WA2k48Y2gZ38E5QIDAQAB\nAoGACDnjJOjJGuf0Sp25nE1dwxWsnXqwmgwmqrolos295zIQ6G3Eo/r4Yi9LLCix\na03uiZgoC1BSu8ykOEfzsxRDjYAjGrcmMpXWl8PRJ9ss129uL17d3LR//MNb2/OP\nSZ6iAGdLg2SoXv8SgCN+5mGCAnltOJcMVhSwn7ao7izekmECQQD/R532qlOXCmAx\n6zUbR1EhchoB3w6QNoO+5CkaIH+A73IEGbr3755/rFGPN6crFtblPwkSmhhCu51t\nuM6qaEq5AkEA1p+ZWpZdnOd7TvuvKJAQIqPzenSyTGVozQ0O9vErfZLDJ+6BkXBU\nvTAUK0whNLm+v7BtEmkoqYl9GXagkjpFjQJAFIIbZaKfXoX93mTH+m4LTYWOI1JZ\nKCrJAL/xsWCk/aW+4idzBtIgSJ9+WeQdsO9/yiD7SJxKkKnj5tmu+K+yOQJBAJft\nMmllt66yTh+DGmLkWAetd1Vf9jcOMjm03LsBzX9+vJcvxphlpBaoSh68LWVddyHK\nietWdWpN4Th9OP1KMqECQF5VPQv6auUG68Vif9FLdsBHTQzQu4viUa14QqLss2wA\nhzNp6aVe0DaIRFGlmkvh7gZAYynEhXMkBqR3Bg+nniA=\n-----END RSA PRIVATE KEY-----\n", "port": 9090} The log file can be found at /tmp/nuclide-pi-logs/server-start/nuclide-2017-06-17T14:52:18.nohup.out.

Versions

test on node: 6.10.0 , 7.10.0

Additional Details

*server use nvm

SuperCipher commented 7 years ago

[solved]

Troubleshooting

when I tried node -v system return v8.4.0. but once tried nodejs --version system return zsh: command not found: node using which nodejs and get no return is confirmed that system can't find NodeJS. google around and found The "node" package is unrelated to "NodeJS".

Solution

Use n module from npm in order to upgrade node

sudo npm cache clean -f
sudo npm install -g n
sudo n stable

sudo ln -sf /usr/local/n/versions/node/<VERSION>/bin/node /usr/bin/nodejs