nativescript-cli: tns run ios issue with 2.5.0 - unable to sync files on iOS Simulator

Output:

Unable to sync files. Error is: cp: copyFileSync: could not write to dest file (code=ENOENT):/Users/toddanglin/Library/Developer/CoreSimulator/Devices/50DFBA8C-A077-4EB4-B49F-93D2FAE13810/data/Containers/Bundle/Application/6878EDAF-504B-4366-9CE4-B5A97870EA3C/ns-demo.app/Resources/en.lproj/Localizable.strings

Seems to fail with the same error on different files in “/Resources/en.lproj”. Here it’s “Localizable.strings.” Sometimes it’s “InfoPlist.strings”.

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 21 (9 by maintainers)

Most upvoted comments

No. This problem returned on TNS 4. ( already reported here https://github.com/NativeScript/nativescript-cli/issues/3630)

Look at this screen where my app is On :

image

Now let’s change something in the code

image

See error :

image

It didn’t happen before in v 3 Files are read only due to TFS. But it did work before v4.

complete package.json :

https://gist.github.com/RoyiNamir/c7adb7454b075369b0d325b88575f374

Hi @Nikoms,

The issue @shakes90 is different from the original issue in this thread. It is already fixed in code base, available in @next builds and will be released in 3.1.0.

How to test with @next builds:

npm un -g nativescript
npm cache clean
npm i -g nativescript@next

OK - found the answer to the above problem - Intellij saves temp files as a “safe write” option which was causing the issue. So if turn off evrything is OK. System Settings => “Use safe write” in intellij

I’m getting a similar problem with the latest version of nativescript 3.0.1 - Very basic setup on Ubuntu 16.04 although my colleagues who work in a windows environment tell my live-sync is OK for them - error as follows when edit a basic ts file from the Hello world app and save:

Executing before-prepare hook from /home/simon/projects/nativescript/HelloWorld/hooks/before-prepare/nativescript-dev-android-snapshot.js Executing before-prepare hook from /home/simon/projects/nativescript/HelloWorld/hooks/before-prepare/nativescript-dev-typescript.js Preparing project… Project successfully prepared (android) Executing after-prepare hook from /home/simon/projects/nativescript/HelloWorld/hooks/after-prepare/nativescript-dev-android-snapshot.js Transferring project files… Unable to sync files. Error is: Multiple errors were thrown: ENOENT: no such file or directory, stat ‘/home/simon/projects/nativescript/HelloWorld/platforms/android/src/main/assets/app/app.component.ts___jb_tmp___’

I still get this aswell.