Nativescript-angular: 'tns build android' results in error - Android building error

Created on 10 Mar 2017  路  2Comments  路  Source: NativeScript/nativescript-angular

I'm running tns build android with all parameters for keyStore, alias, password. The script is building fine until this errors is shown:

ENOENT: no such file or directory, open '/Users/username/Documents/Project/node_modules/nativescript-angular-snapshot/platforms/android-snapshot-files/bundle.records.json'

Cleaning node_modules and platforms didn't work, neither did tns update. This is the full log:

Executing before-prepare hook from /Users/username/Documents/Project/hooks/before-prepare/nativescript-dev-android-snapshot.js
Executing before-prepare hook from /Users/username/Documents/Project/hooks/before-prepare/nativescript-dev-typescript.js
Found peer TypeScript 2.1.6
Preparing project...

:config phase:  createDefaultIncludeFiles

:config phase:  copyAarDependencies

:config phase:  addAarDependencies
    +adding dependency: /Users/username/Documents/Project/platforms/android/libs/aar/widgets-release.aar
Incremental java compilation is an incubating feature.
:asbg:clean UP-TO-DATE
:deleteMetadata
:deleteFlavors
:deleteConfigurations UP-TO-DATE
:clean

BUILD SUCCESSFUL

Total time: 9.079 secs

This build could be faster, please consider using the Gradle Daemon: https://docs.gradle.org/2.10/userguide/gradle_daemon.html
Successfully prepared plugin nativescript-angular for android.
Successfully prepared plugin nativescript-intl for android.
nativescript-iqkeyboardmanager is not supported for android.
Successfully prepared plugin nativescript-iqkeyboardmanager for android.
Successfully prepared plugin nativescript-theme-core for android.
Successfully prepared plugin tns-core-modules for android.
Successfully prepared plugin tns-core-modules-widgets for android.
Project successfully prepared (android)
Executing after-prepare hook from /Users/username/Documents/Project/hooks/after-prepare/nativescript-dev-android-snapshot.js
ENOENT: no such file or directory, open '/Users/username/Documents/Project/node_modules/nativescript-angular-snapshot/platforms/android-snapshot-files/bundle.records.json'

Any help will be appreciated!

question

Most helpful comment

@robbdimitrov I tried the suggestion here and it seems to be working.

https://github.com/NativeScript/android-snapshot/issues/9

I hope it helps!

All 2 comments

Having same issue here, tried also deleting node-modules and platform folder but did not help.
I forgot to add that if I do tns run android is all good, this is only when I'm trying to do tns build android.

@robbdimitrov I tried the suggestion here and it seems to be working.

https://github.com/NativeScript/android-snapshot/issues/9

I hope it helps!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

EricRobertBrewer picture EricRobertBrewer  路  3Comments

sis0k0 picture sis0k0  路  3Comments

vakrilov picture vakrilov  路  3Comments

sarvagayatri picture sarvagayatri  路  3Comments

sunpasup picture sunpasup  路  3Comments