Closed petekanev closed 8 years ago
Hello @Obsessive, there was indeed a problem with the static binding generator closing the running process when a flawed "safety" check passed. Logging is disabled by default there and should not affect you at all unless you wanted to debug the binding generator.
You can fetch the latest fix by doing a tns platform remove android
and then tns platform add android@next
I am still getting this error. Where do I get the older version of the build.gradle file?
@DaneGrinder have you tried fetching the latest (unofficial) build from tns platform add android@next
? If yes, and you are experiencing these crashes, could you post a log with the error?
Yes, I have tried android@next. Same result.
That is a babel error, caused by babel's require. _core.js
is present on my machine. Could you please try deleting node_modules
altogether and running again? Also, what is the version of the babel-traverse
in the package.json?
It works :-) Thanks a lot. Hope it helped you guys fix the bug. Now, really looking forward to start testing on Nativescript.
"devDependencies": { "babel-traverse": "6.7.6", "babel-types": "6.7.7", "babylon": "6.7.0", "filewalker": "0.1.2", "lazy": "1.0.11", "nativescript-dev-typescript": "^0.3.2", "typescript": "^1.8.10" }
Keep up the great work :-)
Hi guys, I have been using NS for a couple of weeks new. Everything seemed perfect until yesterday. For some unknown reasons tns can't build android anymore.
My config:
tns doctor result:
Your components are up-to-date.
No issues were detected.
tns create sampleApp:
Project sampleApp was successfully created.
cd sampleApp; tns platform add android;
... Project successfully created.
tns prepare android
... Project successfully prepared (android) tns build android
:config phase: createDefaultIncludeFiles +found plugins: tns-core-modules-widgets
- creating include.gradle file for /Users/henrisack/workspace/Nativescript/sampleApp/platforms/android/configurations/tns-core-modules-widgets Renaming plugin directory to flavor name: /Users/henrisack/workspace/Nativescript/sampleApp/platforms/android/src/tns-core-modules-widgets -> /Users/henrisack/workspace/Nativescript/sampleApp/platforms/android/src/F0
:config phase: createPluginsConfigFile Creating product flavors include.gradle file in /Users/henrisack/workspace/Nativescript/sampleApp/platforms/android/configurations folder...
:config phase: pluginExtend +applying configuration from: /Users/henrisack/workspace/Nativescript/sampleApp/platforms/android/configurations/include.gradle +applying configuration from: /Users/henrisack/workspace/Nativescript/sampleApp/platforms/android/configurations/tns-core-modules-widgets/include.gradle
:config phase: copyAarDependencies
:config phase: addAarDependencies +adding dependency: /Users/henrisack/workspace/Nativescript/sampleApp/platforms/android/libs/aar/widgets-release.aar Incremental java compilation is an incubating feature. :preBuild UP-TO-DATE :preF0DebugBuild UP-TO-DATE :checkF0DebugManifest :preF0ReleaseBuild UP-TO-DATE :prepareComAndroidSupportAnimatedVectorDrawable2340Library :prepareComAndroidSupportAppcompatV72340Library :prepareComAndroidSupportSupportV42340Library :prepareComAndroidSupportSupportVectorDrawable2340Library :prepareSampleAppRuntimeUnspecifiedLibrary :prepareWidgetsReleaseLibrary :prepareF0DebugDependencies :compileF0DebugAidl :compileF0DebugRenderscript :generateF0DebugBuildConfig :cleanLocalAarFiles :ensureMetadataOutDir :collectAllJars :setProperties :asbg:generateInterfaceNamesList :asbg:runAstParser FAILED
FAILURE: Build failed with an exception.
What went wrong: Execution failed for task ':asbg:runAstParser'.
A problem occurred starting process 'command 'node''
BUILD FAILED
Does anyone has any clue because I am now stuck with an actual project now
@sacketty please check out the discussion going on at https://github.com/NativeScript/NativeScript/issues/2628
I had the same problem with a newly created project, i don't know how i did, but than it finally build succesfully.
Than I run a test: I copied that project that builds successfully on android with a cp -r workingPrj newPrj
and when i launch tns build android
i get that same error.
This means, the same project in a directory builds in another not. hope this helps
C:\Users\Prasad_L\Desktop\test\Helloworld>tns build android Executing before-prepare hook from C:\Users\Prasad_L\Desktop\test\Helloworld\hoo ks\before-prepare\nativescript-dev-android-snapshot.js Executing before-prepare hook from C:\Users\Prasad_L\Desktop\test\Helloworld\hoo ks\before-prepare\nativescript-dev-typescript.js Found peer TypeScript 2.1.6 Preparing project...
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>if "Windows_NT" == " Windows_NT" setlocal
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>set DIRNAME=C:\Users \Prasad_L\Desktop\test\Helloworld\platforms\android\
C:\Users\PrasadL\Desktop\test\Helloworld\platforms\android>if "C:\Users\Prasad L\Desktop\test\Helloworld\platforms\android\" == "" set DIRNAME=.
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>set APP_BASE_NAME=gr adlew
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>set APP_HOME=C:\User s\Prasad_L\Desktop\test\Helloworld\platforms\android\
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>if defined JAVA_HOME goto findJavaFromJavaHome
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>set JAVA_HOME=D:\Jav a\jdk1.8.0_51
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>set JAVA_EXE=D:\Java \jdk1.8.0_51/bin/java.exe
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>if exist "D:\Java\jd k1.8.0_51/bin/java.exe" goto init
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>if not "Windows_NT" == "Windows_NT" goto win9xME_args
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>if "@eval[2+2]" == " 4" goto 4NT_args
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>set CMD_LINE_ARGS=
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>set _SKIP=2
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>if "xclean" == "x" g oto execute
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>set CMD_LINE_ARGS=cl ean -PcompileSdk=android-25 -PtargetSdk=APILEVEL -PbuildToolsVersion=25.0.2 -PsupportVersion=25.2.0 -PgenerateTypings=false
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>goto execute
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>set CLASSPATH=C:\Use rs\Prasad_L\Desktop\test\Helloworld\platforms\android\gradle\wrapper\gradle-wra pper.jar
C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\android>"D:\Java\jdk1.8.0_51 /bin/java.exe" "-Dorg.gradle.appname=gradlew" -classpath "C:\Users\Prasad_L\D esktop\test\Helloworld\platforms\android\gradle\wrapper\gradle-wrapper.jar" org .gradle.wrapper.GradleWrapperMain clean -PcompileSdk=android-25 -PtargetSdk=AP ILEVEL -PbuildToolsVersion=25.0.2 -PsupportVersion=25.2.0 -PgenerateTypings=fa lse
:config phase: createDefaultIncludeFiles
:config phase: copyAarDependencies
:config phase: addAarDependencies +adding dependency: C:\Users\Prasad_L\Desktop\test\Helloworld\platforms\ android\libs\aar\widgets-release.aar
Configuring > 2/3 projects > Resolving dependencies ':_debugCompile'
anyone pls help me
@BhuvaneswariVajravel If you believe this to be an issue coming from NativeScript submit a new issue according the provided template, with enough information that will allow us to reproduce your problem.
From @Obsessive on May 20, 2016 10:34
with the following error :asbg:runAstParser couldn't find logDirectory so it will be created in place:/Volumes/SERVER/root/repos/STS/App-Division/ocd-cheats/platforms/android/build-tools/android-static-binding-generator/ast-parser/logs/i.txt ERROR WRITING TO LOG FILE DIRECTORY : /Volumes/SERVER/root/repos/STS/App-Division/ocd-cheats/platforms/android/build-tools/android-static-binding-generator/ast-parser/logs :asbg:runAstParser FAILED
FAILURE: Build failed with an exception.
What went wrong: Execution failed for task ':asbg:runAstParser'.
Seems to be reproducible on OS X .
Which platform(s) does your issue occur on?
Android
Please provide the following version numbers that your issue occurs with:
No issues were detected.
Please tell us how to recreate the issue in as much detail as possible.
(also tried with tns build android@next)
Temporary fix
Temporary fix : replace the build.gradle file from previous version of nativescript (1.7.1) in /platform/android
Copied from original issue: NativeScript/NativeScript#2157