Skip to content

Instantly share code, notes, and snippets.

@tjvantoll
Created October 17, 2017 19:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tjvantoll/e1b54773c66469e57cf1b2fde687919e to your computer and use it in GitHub Desktop.
Save tjvantoll/e1b54773c66469e57cf1b2fde687919e to your computer and use it in GitHub Desktop.
$ npm run start-android-bundle --uglify --snapshot
> @ start-android-bundle /Users/tj/dev/play/PerfTesting
> npm run ns-bundle --android --run-app
> @ ns-bundle /Users/tj/dev/play/PerfTesting
> ns-bundle
Running tns prepare...
Executing before-prepare hook from /Users/tj/dev/play/PerfTesting/hooks/before-prepare/nativescript-dev-typescript.js
Preparing project...
Project successfully prepared (android)
:config phase: createDefaultIncludeFiles
+found plugins: tns-core-modules-widgets
:config phase: createPluginsConfigFile
Creating product flavors include.gradle file in /Users/tj/dev/play/PerfTesting/platforms/android/configurations folder...
:config phase: pluginExtend
+applying configuration from: /Users/tj/dev/play/PerfTesting/platforms/android/configurations/include.gradle
+applying configuration from: /Users/tj/dev/play/PerfTesting/platforms/android/configurations/tns-core-modules-widgets/include.gradle
:config phase: addAarDependencies
+adding dependency: /Users/tj/dev/play/PerfTesting/platforms/android/libs/aar/widgets-release.aar
The JavaCompile.setDependencyCacheDir() method has been deprecated and is scheduled to be removed in Gradle 4.0.
The TaskInputs.source(Object) method has been deprecated and is scheduled to be removed in Gradle 4.0. Please use TaskInputs.file(Object).skipWhenEmpty() instead.
Incremental java compilation is an incubating feature.
The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead.
at build_68eoliy8ttbfxqv64xumbj4f3.run(/Users/tj/dev/play/PerfTesting/platforms/android/build-tools/android-static-binding-generator/build.gradle:144)
:asbg:clean
:deleteMetadata
:deleteFlavors
:deleteConfigurations
:deleteGeneratedBindings
:clean
BUILD SUCCESSFUL
Total time: 2.239 secs
Running webpack for android...
Project root: /Users/tj/dev/play/PerfTesting
Snapshots build directory: /Users/tj/dev/play/PerfTesting/platforms/android/snapshot-build/build
undefined
10% building modules 1/3 modules 2 active ...tj/dev/play/PerfTesting/app/vendor.ts(node:15861) DeprecationWarning: loaderUtils.parseQuery() received a non-string value which can be problematic, see https://github.com/webpack/loader-utils/issues/56
parseQuery() will be replaced with getOptions() in the next major version of loader-utils.
95% emitting
Snapshotting bundle at /Users/tj/dev/play/PerfTesting/platforms/android/src/main/assets/app/vendor.js
Running snapshot generation with the following arguments:
{
"inputFile": "/Users/tj/dev/play/PerfTesting/platforms/android/src/main/assets/app/vendor.js",
"preprocessedInputFile": "/Users/tj/dev/play/PerfTesting/platforms/android/src/main/assets/app/_embedded_script_.js",
"targetArchs": [
"arm",
"arm64",
"ia32"
],
"useLibs": false,
"tnsJavaClassesPath": "/Users/tj/dev/play/PerfTesting/platforms/android/src/main/assets/app/tns-java-classes.js"
}
Snapshot tools path: /var/folders/cn/nsbk1gdx1qx8j432ypn682080000gn/T/snapshot-tools
***** Generating snapshot for armeabi-v7a *****
***** Generating snapshot for arm64-v8a *****
***** Generating snapshot for x86 *****
***** SNAPSHOT GENERATION FOR arm64-v8a FAILED! *****
/bin/sh: /var/folders/cn/nsbk1gdx1qx8j432ypn682080000gn/T/snapshot-tools/mksnapshot-tools/v8-v5.5.372.32/darwin-x64/mksnapshot-arm64: Permission denied
Snapshot generation failed with the following error:
Error: Cannot find suitable v8 version! Original error: /bin/sh: /var/folders/cn/nsbk1gdx1qx8j432ypn682080000gn/T/snapshot-tools/mksnapshot-tools/v8-v5.5.372.32/darwin-x64/mksnapshot-arm64: Permission denied
at getV8Version.then.catch.error (/Users/tj/dev/play/PerfTesting/node_modules/nativescript-dev-webpack/snapshot/android/project-snapshot-generator.js:254:15)
at process._tickCallback (internal/process/next_tick.js:103:7)
Hash: 7ce63205f8471572676e
Version: webpack 3.2.0
Time: 14372ms
Asset Size Chunks Chunk Names
bundle.js 32.3 kB 0 [emitted] bundle
tns-java-classes.js 369 bytes 1 [emitted] tns-java-classes
app.css.js 169 bytes 2 [emitted] app.css
vendor.js 1.26 MB 3 [emitted] [big] vendor
app.css 14.2 kB 2 [emitted] app.css
package.json 178 bytes [emitted]
starter.js 39 bytes [emitted]
[37] ./item/item.service.ts 1.58 kB {0} [built]
[71] ./item/items.component.ts 842 bytes {0} [built]
[72] ./item/item-detail.component.ts 784 bytes {0} [built]
[120] .. lazy 160 bytes {3} [built]
[166] ./main.aot.ts 465 bytes {0} [built]
[211] ./app.module.ngfactory.ts 6.96 kB {0} [built]
[212] ./app.module.ts 640 bytes {0} [built]
[214] ./item/items.component.ngfactory.ts 7.6 kB {0} [built]
[252] ./item/item-detail.component.ngfactory.ts 4.67 kB {0} [built]
[253] ./app.component.ngfactory.ts 2.89 kB {0} [built]
[259] ./app.routing.ts 631 bytes {0} [built]
[260] ./vendor.ts 394 bytes {3} [built]
[261] ./vendor-platform.android.ts 457 bytes {3} [built]
[275] ./app.css 41 bytes {2} [built]
[276] ../platforms/android/snapshot-build/tns-java-classes.js 59 bytes {1} [built]
+ 264 hidden modules
Child app/app.component.html:
[0] ./app.component.html 167 bytes {0} [built]
Child app/item/items.component.html:
[0] ./item/items.component.html 1.74 kB {0} [built]
Child app/item/item-detail.component.html:
[0] ./item/item-detail.component.html 394 bytes {0} [built]
Child extract-text-webpack-plugin /Users/tj/dev/play/PerfTesting/node_modules/extract-text-webpack-plugin/dist /Users/tj/dev/play/PerfTesting/node_modules/resolve-url-loader/index.js??ref--1-1!/Users/tj/dev/play/PerfTesting/node_modules/nativescript-css-loader/index.js??ref--1-2!/Users/tj/dev/play/PerfTesting/node_modules/nativescript-dev-webpack/platform-css-loader.js!/Users/tj/dev/play/PerfTesting/app/app.css:
[1] ../node_modules/resolve-url-loader?{"silent":true,"absolute":false,"sourceMap":false,"fail":false,"keepQuery":false,"debug":false,"root":null,"includeRoot":false}!../node_modules/nativescript-css-loader?{"minimize":false}!../node_modules/nativescript-dev-webpack/platform-css-loader.js!./app.css 776 bytes {0} [built]
+ 2 hidden modules
***** SNAPSHOT GENERATION FOR armeabi-v7a FAILED! *****
/bin/sh: /var/folders/cn/nsbk1gdx1qx8j432ypn682080000gn/T/snapshot-tools/mksnapshot-tools/v8-v5.5.372.32/darwin-x64/mksnapshot-arm: Permission denied
Webpack Bundle Analyzer saved stats file to /Users/tj/dev/play/PerfTesting/report/stats.json
Webpack Bundle Analyzer saved report to /Users/tj/dev/play/PerfTesting/report/report.html
***** SNAPSHOT GENERATION FOR x86 FAILED! *****
/bin/sh: /var/folders/cn/nsbk1gdx1qx8j432ypn682080000gn/T/snapshot-tools/mksnapshot-tools/v8-v5.5.372.32/darwin-x64/mksnapshot-ia32: Permission denied
cp: no such file or directory: /Users/tj/dev/play/PerfTesting/platforms/android/snapshot-build/build/include.gradle
Running tns run...
Searching for devices...
Executing before-prepare hook from /Users/tj/dev/play/PerfTesting/hooks/before-prepare/nativescript-dev-typescript.js
Preparing project...
Gradle build...
:config phase: createDefaultIncludeFiles
+found plugins: nativescript-android-snapshot
+ creating include.gradle file for /Users/tj/dev/play/PerfTesting/platforms/android/configurations/nativescript-android-snapshot
:config phase: createPluginsConfigFile
Creating product flavors include.gradle file in /Users/tj/dev/play/PerfTesting/platforms/android/configurations folder...
:config phase: pluginExtend
+applying configuration from: /Users/tj/dev/play/PerfTesting/platforms/android/configurations/include.gradle
+applying configuration from: /Users/tj/dev/play/PerfTesting/platforms/android/configurations/nativescript-android-snapshot/include.gradle
:config phase: addAarDependencies
+adding dependency: /Users/tj/dev/play/PerfTesting/platforms/android/libs/aar/widgets-release.aar
Project successfully prepared (Android)
Building project...
Gradle build...
:config phase: createDefaultIncludeFiles
+found plugins: tns-core-modules-widgets
+ creating include.gradle file for /Users/tj/dev/play/PerfTesting/platforms/android/configurations/tns-core-modules-widgets
Renaming plugin directory to flavor name: /Users/tj/dev/play/PerfTesting/platforms/android/src/tns-core-modules-widgets -> /Users/tj/dev/play/PerfTesting/platforms/android/src/F0
:config phase: createPluginsConfigFile
Creating product flavors include.gradle file in /Users/tj/dev/play/PerfTesting/platforms/android/configurations folder...
:config phase: pluginExtend
+applying configuration from: /Users/tj/dev/play/PerfTesting/platforms/android/configurations/include.gradle
+applying configuration from: /Users/tj/dev/play/PerfTesting/platforms/android/configurations/tns-core-modules-widgets/include.gradle
:config phase: addAarDependencies
+adding dependency: /Users/tj/dev/play/PerfTesting/platforms/android/libs/aar/widgets-release.aar
Running full build
finished with reading lines with js files
Warning: there already is an extend called com.tns.FragmentClass.
Warning: The static binding generator will generate extend from:_embedded_script_.js implementation
Warning: there already is an extend called com.tns.NativeScriptActivity.
Warning: The static binding generator will generate extend from:_embedded_script_.js implementation
Exception in thread "main" java.io.IOException: File already exists. This may lead to undesired behavior.
Please change the name of one of the extended classes.
File:/Users/tj/dev/play/PerfTesting/platforms/android/src/main/java/com/tns/FragmentClass.java Class: com.tns.FragmentClass
at org.nativescript.staticbindinggenerator.Generator.writeBindings(Generator.java:68)
at org.nativescript.staticbindinggenerator.Main.main(Main.java:15)
FAILURE: Build failed with an exception.
* Where:
Build file '/Users/tj/dev/play/PerfTesting/platforms/android/build-tools/android-static-binding-generator/build.gradle' line: 277
* What went wrong:
Execution failed for task ':asbg:generateBindings'.
> Process 'command '/Library/Java/JavaVirtualMachines/jdk1.8.0_65.jdk/Contents/Home/bin/java'' finished with non-zero exit value 1
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
Command ./gradlew failed with exit code 1
# run android
┌────────────────────────────────────────────────────┬───────────────────────────────────────────────────────────────────────────┐
│ Usage │ Synopsis │
│ Run on all connected devices and running emulators │ $ tns run android [--key-store-path <File Path> --key-store-password │
│ │ <Password> --key-store-alias <Name> --key-store-alias-password <Password> │
│ │ ] [--release] [--justlaunch] │
│ Run on a selected connected device or running │ $ tns run android --device <Device ID> [--key-store-path <File Path> - │
│ emulator. Will start emulator with specified │ -key-store-password <Password> --key-store-alias <Name> --key-store-alias │
│ Device Identifier, if not already running. │ -password <Password>] [--release] [--justlaunch] │
│ Start a default emulator if none are running, or │ $ tns run android --emulator [--key-store-path <File Path> --key-store │
│ run application on all connected emulators. │ -password <Password> --key-store-alias <Name> --key-store-alias-password │
│ │ <Password>] [--release] [--justlaunch] │
└────────────────────────────────────────────────────┴───────────────────────────────────────────────────────────────────────────┘
Runs your project on a connected Android device or in a native Android emulator, if configured. This is shorthand for prepare, build and deploy. While your app is running, prints the output from the application in the console and watches for changes in your code. Once a change is detected, it synchronizes the change with all selected devices and restarts/refreshes the application.
### Options
* --device - Specifies a connected device/emulator to start and run the app.
* --emulator - If set, runs the app in all available and configured android emulators. It will start an emulator if none are already running.
* --justlaunch - If set, does not print the application output in the console.
* --clean - If set, forces rebuilding the native application.
* --no-watch - If set, changes in your code will not be reflected during the execution of this command.
* --release - If set, produces a release build. Otherwise, produces a debug build. When set, you must also specify the --key-store-* options.
* --key-store-path - Specifies the file path to the keystore file (P12) which you want to use to code sign your APK. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
* --key-store-password - Provides the password for the keystore file specified with --key-store-path. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
* --key-store-alias - Provides the alias for the keystore file specified with --key-store-path. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
* --key-store-alias-password - Provides the password for the alias specified with --key-store-alias-password. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
### Attributes
* <Device ID> is the index or Device Identifier of the target device as listed by $ tns device android --available-devices
child process exited with code 127
npm ERR! Darwin 16.7.0
npm ERR! argv "/usr/local/Cellar/node@6/6.9.1/bin/node" "/usr/local/bin/npm" "run" "ns-bundle" "--android" "--run-app"
npm ERR! node v6.9.1
npm ERR! npm v3.10.8
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! @ ns-bundle: `ns-bundle`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the @ ns-bundle script 'ns-bundle'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! ns-bundle
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /Users/tj/dev/play/PerfTesting/npm-debug.log
npm ERR! Darwin 16.7.0
npm ERR! argv "/usr/local/Cellar/node@6/6.9.1/bin/node" "/usr/local/bin/npm" "run" "start-android-bundle" "--uglify" "--snapshot"
npm ERR! node v6.9.1
npm ERR! npm v3.10.8
npm ERR! code ELIFECYCLE
npm ERR! @ start-android-bundle: `npm run ns-bundle --android --run-app`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @ start-android-bundle script 'npm run ns-bundle --android --run-app'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! npm run ns-bundle --android --run-app
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /Users/tj/dev/play/PerfTesting/npm-debug.log
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment