Skip to content

Livesync android device using 1.5 - ENAMTOOLONG error #1246

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

Closed
N3ll opened this issue Nov 25, 2015 · 15 comments
Closed

Livesync android device using 1.5 - ENAMTOOLONG error #1246

N3ll opened this issue Nov 25, 2015 · 15 comments

Comments

@N3ll
Copy link
Contributor

N3ll commented Nov 25, 2015

From @GitCharm on November 25, 2015 10:53

Using NS 1.5 - calling tns livesync android using a connected android device is generating the following error:

Project successfully prepared
Transferring project files...
spawn ENAMETOOLONG

What does this mean and is there something I can change at my end?

Copied from original issue: NativeScript/NativeScript#1155

@bradmartin
Copy link

+1 same issue after updating to 1.5

 tns livesync android --watch

also throws the same error.

 tns doctor

is reporting no issues.

I've also uninstalled the application on the device, then ran livesync to install it. Same result.

--log trace

ends up with the error at FiberFuture.Future.wait (..\node_modules\nativescript\node_modules\fibers\future.js:535:15)

@victorhugom-zz
Copy link

+1

@afortaleza
Copy link

+1

My output http://pastebin.com/26KqbRzy

@afortaleza
Copy link

I have setup nativescript 1.5 in a VM running Linux (Xubuntu 15.04) and the problem does not happen there. It's probably a windows related issue.

@bradmartin
Copy link

Yea I think windows has a file path limit of 256 and it's an issue with
many node programs. There was even a really long thread on npm github about
file paths and how node does folders/files.

On 8:43pm, Wed, Nov 25, 2015 Anderson Fortaleza notifications@github.com
wrote:

I have setup nativescript 1.5 in a VM running Linux (Xubuntu 15.04) and
the problem does not happen there. It's probably a windows related issue.


Reply to this email directly or view it on GitHub
#1246 (comment)
.

@kvelikov
Copy link

Hi guys,
I have the same problem. This is the log I get:
Error: spawn ENAMETOOLONG
at FiberFuture.Future.wait (C:\Users\kvelikov\AppData\Roaming\npm\node_modul
es\nativescript\node_modules\fibers\future.js:535:15)
at C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativescript\lib\commo
n\errors.js:109:33
at Function.settle (C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativ
escript\node_modules\fibers\future.js:249:26)
at FiberFuture.Future.wait (C:\Users\kvelikov\AppData\Roaming\npm\node_modul
es\nativescript\node_modules\fibers\future.js:534:10)
at C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativescript\lib\commo
n\services\commands-service.js:87:106
at Function.settle (C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativ
escript\node_modules\fibers\future.js:249:26)
at FiberFuture.Future.wait (C:\Users\kvelikov\AppData\Roaming\npm\node_modul
es\nativescript\node_modules\fibers\future.js:534:10)
at C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativescript\lib\commo
n\dispatchers.js:38:85
at Function.settle (C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativ
escript\node_modules\fibers\future.js:249:26)
at FiberFuture.Future.wait (C:\Users\kvelikov\AppData\Roaming\npm\node_modul
es\nativescript\node_modules\fibers\future.js:534:10)
at C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativescript\lib\nativ
escript-cli.js:20:45
- - - - -
at exports._errnoException (util.js:874:11)
at ChildProcess.spawn (internal/child_process.js:298:11)
at Object.exports.spawn (child_process.js:339:9)
at ChildProcess.spawn (C:\Users\kvelikov\AppData\Roaming\npm\node_modules\na
tivescript\lib\common\child-process.js:46:30)
at ChildProcess.spawnFromEvent (C:\Users\kvelikov\AppData\Roaming\npm\node_m
odules\nativescript\lib\common\child-process.js:54:33)
at C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativescript\lib\commo
n\mobile\android\android-debug-bridge.js:15:40
at Function.settle (C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativ
escript\node_modules\fibers\future.js:249:26)
at FiberFuture.Future.wait (C:\Users\kvelikov\AppData\Roaming\npm\node_modul
es\nativescript\node_modules\fibers\future.js:534:10)
at C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativescript\lib\commo
n\mobile\android\android-device-file-system.js:44:66
at Function.settle (C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativ
escript\node_modules\fibers\future.js:249:26)
at FiberFuture.Future.wait (C:\Users\kvelikov\AppData\Roaming\npm\node_modul
es\nativescript\node_modules\fibers\future.js:534:10)
at C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativescript\lib\commo
n\services\usb-livesync-service-base.js:143:106
at Function.settle (C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativ
escript\node_modules\fibers\future.js:249:26)
at FiberFuture.Future.wait (C:\Users\kvelikov\AppData\Roaming\npm\node_modul
es\nativescript\node_modules\fibers\future.js:534:10)
at C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativescript\lib\commo
n\services\usb-livesync-service-base.js:189:121
at Function.settle (C:\Users\kvelikov\AppData\Roaming\npm\node_modules\nativ
escript\node_modules\fibers\future.js:249:26)
Analytics statuses:
{ TrackFeatureUsage: 1, TrackExceptions: 0 }
Trying to track feature 'CLI' with value 'help'.
List of registered commands: /?, autocomplete, autocomplete|disable, autocomplet
e|enable, autocomplete|status, build, build|android, build|ios, create, debug, d
ebug|android, debug|ios, deploy, dev-post-install, dev-preuninstall, dev-test, d
ev-test|android, dev-test|ios, device, device|android, device|get-file, device|i
os, device|list-applications, device|list-files, device|log, device|put-file, de
vice|run, device|stop, device|uninstall, doctor, emulate, emulate|android, emula
te|ios, error-reporting, help, init, install, library, library|add, livesync, pl
atform, platform|add, platform|remove, platform|update, plugin, plugin|add, plug
in|remove, prepare, run, run|android, run|ios, test, test|android, test|init, te
st|ios, usage-reporting
Reading help for command 'livesync'. FileName is 'livesync.md'.

@BenElliottBV
Copy link

I also get this issue - log ends with the same issue as @bradmartin -

ends up with the error at FiberFuture.Future.wait (..\node_modules\nativescript\node_modules\fibers\future.js:535:15)

@bradmartin
Copy link

Can this be prioritized and patched? LiveSync is dead on windows. Is there a workaround or anything, 'tns run' is just too time consuming.

@rosen-vladimirov
Copy link
Contributor

Hi @bradmartin ,
The issue is already fixed in our release branch and in case it is urgent for you, I suggest you to build the nativescript-cli source on your own.
Here are the base steps that you have to execute:

  1. git clone git@github.com:NativeScript/nativescript-cli.git
  2. cd nativescript-cli
  3. git submodule init
  4. git checkout release
  5. git submodule update
  6. npm i -g grunt-cli
  7. npm install
  8. grunt
  9. Add <path to nativescript-cli>/bin to your PATH
  10. Restart your shell/command prompt.
  11. Verify nativescript is used from bin folder by executing where tns and make sure the first result is the PATH from step 8

Now you can execute any tns command directly and the ENAMETOOLONG error should not exist anymore :)

The official fix will be included in our incoming 1.5.1 release.

@bradmartin
Copy link

Thanks for the steps to build the source. I forgot about, hopefully this will help the others. Thanks again!

@NathanaelA

This comment was marked as abuse.

@bradmartin
Copy link

I think I tried that but still had the error @NathanaelA. I assumed I was doing something wrong. I'll try again and let you know if that works out. Can you confirm that the patch fixes this on windows or anyone else?

@lyonzy
Copy link

lyonzy commented Nov 30, 2015

If you want a hack solution, I just compiled the typescript files here and copied them over the javascript in \node_modules\nativescript\lib\common\mobile\android. I can confirm that the issue seems to be fixed on windows.

@bradmartin
Copy link

Thanks @NathanelA and @Iyonzy. Using the nativescript.rocks build fixed it. I just had to find the folder where it was installing. It wasn't overwriting my Nativescript cli from 1.5 so I had to copy it over. Thanks again.

@NathanaelA

This comment was marked as abuse.

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

No branches or pull requests