android: Gradle daemon setting 'org.gradle.parallel=true' not supported
@KingAndroid commented on Thu Jul 06 2017
I’ve upgrade ns.
| Component | Current version | Latest version | Information |
|---|---|---|---|
| nativescript | 3.1.1 | 3.1.1 | Up to date |
| tns-core-modules | 3.1.0 | 3.1.0 | Up to date |
| tns-android | 3.1.1 | 3.1.1 | Up to date |
| tns-ios | 3.1.0 | 3.1.0 | Up to date |
Now I can compile ios successfully, but not on android. While I compile android, it stops on here. `:asbg:generateBindings Exception in thread “main” java.lang.NullPointerException at org.nativescript.staticbindinggenerator.Generator.readDir(Generator.java:289) at org.nativescript.staticbindinggenerator.Generator.readClasses(Generator.java:244) at org.nativescript.staticbindinggenerator.Generator.<init>(Generator.java:50) at org.nativescript.staticbindinggenerator.Generator.<init>(Generator.java:44) at org.nativescript.staticbindinggenerator.Main.main(Main.java:15) :asbg:generateBindings FAILED
FAILURE: Build failed with an exception.
-
Where: Build file ‘/Users/admin/Desktop/WORK/barcode/platforms/android/build-tools/android-static-binding-generator/build. gradle’ line: 254
-
What went wrong: Execution failed for task ‘:asbg:generateBindings’.`
Could you please let me know resolution and why? Thank you.
@Pip3r4o commented on Thu Jul 06 2017
Hey @KingAndroid, in order to help you, we need additional information regarding your setup, as well as the plugins used in your project, so ideally sharing your package.json content, and whether you extend a native class would help us.
In addition you could run the build with the --log trace flag like so - tns run android --log trace and share the output, so we get a clue at what might be failing the build.
Please fill out the template accordingly when logging an issue or a feature request in the future.
Thank you!
@KingAndroid commented on Wed Jul 12 2017
Hey @Pip3r4o I am sorry, I have tried for 5 hrs and I give up. I have downgrade 3.0.3 and all works well now.
Here are what I can provide for now.
node : 6.11.0 npm : 3.10.0 Package.json
"nativescript": {
"id": "uk.co.barcodeapp",
"tns-android": {
"version": "3.0.1"
},
"tns-ios": {
"version": "3.0.1"
}
},
"dependencies": {
"moment": "2.18.1",
"nativescript-geolocation": "^3.0.0",
"nativescript-ios-uuid": "^1.0.0",
"nativescript-loading-indicator": "^2.3.2",
"nativescript-plugin-firebase": "^3.12.0",
"nativescript-screen-orientation": "^2.0.0",
"tns-core-modules": "^3.0.1"
},
"devDependencies": {
"babel-traverse": "^6.25.0",
"babel-types": "^6.25.0",
"babylon": "^6.17.3",
"lazy": "^1.0.11"
}
}
Thank you.
@sveri commented on Sun Jul 09 2017
I have the same problem here, just installed nativescript from scratch, created a new project and ran:
tns rund android
tns --version 3.1.2
npm --version 3.10.9
node --version v6.9.2
@Pip3r4o commented on Sun Jul 09 2017
Hey @sveri unfortunately that information isn’t sufficient, as I can’t reproduce the problem locally. Please provide the information as requested in my previous comment. Thank you!
@sveri commented on Sun Jul 09 2017
On your demand 😃
@sveri commented on Sun Jul 09 2017
I also have the same problem when using nativescript 3.0.3
@Pip3r4o commented on Thu Jul 13 2017
@sveri thanks for the log! I discovered that the generateBindings is not passed any jars as inputs, thus causing the build error. There wasn’t anything else out of the ordinary that I could spot based on the log.
I’d advise you to invalidate the gradle cache located in the user directory/.gradle/cache, re-add the platform and retry a build.
Thanks
@sveri commented on Fri Jul 14 2017
I just tried that and the error is still the same. I also deleted my nodejs installation and reinstalled everything, my versions are now these:
npm -v && node -v
4.0.0
v6.11.0
@pkoleva commented on Fri Jul 14 2017
Issue moved to NativeScript/NativeScript #4553 via ZenHub
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 22 (5 by maintainers)
Also worth mentioning, still doesn’t work with the gradle daemon – if you try to use it, the APK will not install because the manifest is corrupted somehow, using any version, @latest, or @next.
tbh I cannot understand that none of the core developers uses the gradle daemon? While I could slap myself for not thinking of this, working with gradle, at least the usage of the daemon is recommended since years. I am not sure about the status of the parallel feature, but that is known to cause problems from time to time.
Edit Also I would suggest to document this somewhere prominently please.