iann0036/cloud9-sync

chdir(2) failed.: No such file or directory

github-jorgem opened this issue · 9 comments

OS: MacOS Mojave 10.14.5
VS Code: Version 1.35.1 (1.35.1)
Extension: v0.9.10

I right-click and "Create Terminal". A terminal opens, but the only thing I see is:

chdir(2) failed.: No such file or directory

I'm not able to CTRL + C or CTRL + D, looks like the connection is active. This is the output of the developer tools just for this action.

workbench.main.js:238 [Extension Host] opened server on {address: "127.0.0.1", family: "IPv4", port: 54880}
workbench.main.js:238 [Extension Host] SOCKET OBTAINED
workbench.main.js:238 [Extension Host] Sending:
workbench.main.js:238 [Extension Host] 4{"ack":10219,"seq":20154,"d":["tmux","",{"cwd":"/home/ec2-user/environment","cols":125,"rows":33,"name":"xterm-color","base":"/home/ec2-user/.c9","attach":false,"session":"cloud9_terminal_496","output":false,"terminal":true,"detachOthers":true,"defaultEditor":false,"encoding":"utf8","command":"bash -l"},{"$":90}]}
workbench.main.js:238 [Extension Host] init'd remote terminal
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20154,"seq":10220,"d":[90,null,{"pty":{"id":15,"readable":true,"writable":true,"pid":2391}}]}
workbench.main.js:238 [Extension Host] Terminal Process Created
workbench.main.js:238 [Extension Host] TERMINAL PROCESS DATA
workbench.main.js:238 [Extension Host]% {id: 15, readable: true, writable: true, pid: 2391}
workbench.main.js:238 [Extension Host]% {connecting: false, _hadError: false, _handle: {…}, _parent: null, _host: null, …}
workbench.main.js:238 [Extension Host] Sending:
workbench.main.js:238 [Extension Host] 4{"ack":10220,"seq":20155,"d":["resize",2391,159,33]}
workbench.main.js:238 [Extension Host] Sending:
workbench.main.js:238 [Extension Host] 4{"ack":10220,"seq":20156,"d":["tmux","",{"capturePane":{"start":-32768,"end":1000,"pane":"cloud9_terminal_496:0.0"},"encoding":"utf8","name":"xterm-color","command":""},{"$":15}]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20154,"seq":10221,"d":["onData",15,"chdir(2) failed.: No such file or directory"]}
workbench.main.js:238 [Extension Host] Emitting terminal data
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20154,"seq":10222,"d":["onData",15,"\r\n"]}
workbench.main.js:238 [Extension Host] Emitting terminal data
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20154,"seq":10223,"d":["onProcessClose",2391,null,null]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20154,"seq":10224,"d":["onClose",15]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20154,"seq":10225,"d":["onProcessClose",2391,null,null]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20154,"seq":10226,"d":["onClose",15]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20154,"seq":10227,"d":["onExit",2391,1,0]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20156,"seq":10228,"d":[15,null,{"process":{"pid":2393,"stdin":{"id":16,"readable":false,"writable":true},"stdout":{"id":17,"readable":true,"writable":false},"stderr":{"id":18,"readable":true,"writable":false}}}]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20156,"seq":10229,"d":["onData",18,"can't find session cloud9_terminal_496\n"]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20156,"seq":10230,"d":["onEnd",18,null]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20156,"seq":10231,"d":["onEnd",17,null]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20156,"seq":10232,"d":["onClose",16]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20156,"seq":10233,"d":["onExit",2393,1,null]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20156,"seq":10234,"d":["onProcessClose",2393,1,null]}
workbench.main.js:238 [Extension Host] Sending:
workbench.main.js:238 [Extension Host] 4{"ack":10234,"seq":20157,"d":["call","ping","ping",["serverTime",{"$":32}]]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20157,"seq":10235,"d":[32,null,{"serverTime":2}]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 3
workbench.main.js:238 [Extension Host] Sending:
workbench.main.js:238 [Extension Host] 4{"ack":10235,"seq":20158,"d":["call","ping","ping",["serverTime",{"$":32}]]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20158,"seq":10236,"d":[32,null,{"serverTime":2}]}
workbench.main.js:238 [Extension Host] Sending:
workbench.main.js:238 [Extension Host] 4{"ack":10236,"seq":20159,"d":["call","ping","ping",["serverTime",{"$":32}]]}
workbench.main.js:238 [Extension Host] ---GOT MESSAGE---
workbench.main.js:238 [Extension Host] 4{"ack":20159,"seq":10237,"d":[32,null,{"serverTime":2}]}

Hi @iann0036 and @github-jorgem

Have you managed to address this problem?

image

@igorjunio2015 Nope and crickets from the developer.

Hi @igorjunio2015, @github-jorgem,

Apologies for the very delayed response!

I've never been able to replicate this personally. Are the following files available in your environment?

/home/ec2-user/environment
/home/ec2-user/.c9

bside commented

Hi @iann0036 !
I have an environment running on ubuntu, not amazon linux, so my username is "ubuntu", not "ec2-user". My home directory is located in /home/ubuntu.
Maybe that's the reason?

Hey @bside,

Thanks for your observation!

I've added logic to compensate for the Ubuntu-based environment (and any custom EC2 environment) into version 0.10.1

Could you give it a shot and let me know if this solves your problem?

bside commented

Man, that was ridiculously fast. Works perfect!

image

Thanks @iann0036, awesome work.

Thanks for confirming @bside!

@github-jorgem and @igorjunio2015, does this fix solve for yourselves?

I just took the test here ...

It worked perfectly, thank you for the solution.

Confirmed. This is working. Thanks.