Nativescript android build error - nativescript

Today all of a sudden I was unable to build my app for android on {N} 2.0.1
This is the error I get at the end of the process :
Execution failed for task ':processF0DebugResources'.
> com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command '/usr/local/opt/android-sdk/build-tools/23.0.3/aapt'' finished with non-zero exit value 1
What is causing this?

Removing and than adding the platform solved my issue
tns platform remove android
tns platform add android

Related

Execution failed for task ':app:processDebugResources'. React-Native-Cli setup in android

After setup of react-native-cli and I have the run the app .I am getting this
What went wrong:
Execution failed for task ':app:processDebugResources'.
A failure occurred while executing com.android.build.gradle.internal.res.LinkApplicationAndroidResourcesTask$TaskAction
Android resource linking failed
ERROR:C:\Users\Pallavi\React\Redux\android\app\build\intermediates\packaged_manifests\debug\AndroidManifest.xml:14: AAPT: error: resource style/Theme.GFGPagination (aka com.redux:style/Theme.GFGPagination) not found.
cd android //Navigate into the android folder from the root directory
./gradlew clean // Run this

how can i fix this issue

when i run flutter run in my project, the compile failed. i got this code in verbose mode
ADMIN#ZIRCON-KH101 MINGW64 ~/Documents/android project/new/flutternewsapp-10/codecanyon-26536344-classic-flutter-news-app-best-for-news-blog-and-magazines/01. Flutter/classic_flutter_news
$ flutter run
Using hardware rendering with device Android SDK built for x86. If you get graphics artifacts, consider enabling software rendering with
"--enable-software-rendering".
Launching lib\main.dart on Android SDK built for x86 in debug mode...
Target debug_android_application failed: FileSystemException: Creation failed, path = 'C:\Users\ADMIN\Documents\android project\new\flutternewsapp-10\codecanyon-26536344-classic-flutter-news-app-best-for-news-blog-and-magazines\01. Flutter\classic_flutter_news\build\app\intermediates\flutter\debug\flutter_assets\packages/cupertino_icons' (OS Error: The filename or extension is too long.
, errno = 206)
build failed.
FAILURE: Build failed with an exception.
* Where:
Script 'C:\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 882
* What went wrong:
Execution failed for task ':app:compileFlutterBuildDebug'.
> Process 'command 'C:\flutter\bin\flutter.bat'' 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. Run with --scan to get full
insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 21s
Running Gradle task 'assembleDebug'...
Running Gradle task 'assembleDebug'... Done 23.9s
Exception: Gradle task assembleDebug failed with exit code 1
how can i fix this issues cause i already run flutter packages get, flutter clean inside my project and pass my release to stable channel
Your File path is too long.
C:\Users\ADMIN\Documents\android project\new\flutternewsapp-10\codecanyon-26536344-classic-flutter-news-app-best-for-news-blog-and-magazines\01. Flutter\classic_flutter_news\build\app\intermediates\flutter\debug\flutter_assets\packages/cupertino_icons
this exceeds some limitations in compilers and some programs.
so simply move your project folder to something simple like C:\Projest\
also change the name of this folder to something shorter
codecanyon-26536344-classic-flutter-news-app-best-for-news-blog-and-magazines

Can't generate the APK

The App works perfectly in debug variant but when I change it to release variant the build fails and it gives me this error: java.util.concurrent.ExecutionException: com.android.builder.internal.aapt.v2.Aapt2Exception: AAPT2 error: check logs for details, and also on my java classes (setContentView(R.layout.activity_main)) the R tells me it can't resolve symbol 'R'.
This only happens when I change the build variant to release to finish the app.
Thank you in advance!

Invalid Request upon trying run in simulator

I cannot seem to run anything via iOS simulator in appcelerator today:
STUDIO BUILD: 4.7.0.201607250649
SDK :5.4.0 (have tried a few different sdks versions)
When trying to run I get:
[INFO] : Alloy compiled in 0.65622s [INFO] : Alloy compiler completed successfully [ERROR] : invalid request
That was for existing projects...
When I tried a new project I got a message stating:
The project has an invalid/non-platform GUID. and cannot be run. Would yo like to register the app with the platform, updating its GUID?
Upon clicking yes it does nothing to resolve the issue.
Invalid Request seems to trigger when there is an issue with your authentication with Appcelerator.
Go to terminal a log in again: appc login.
All should work after you've logged in.

gradle build error after adding facebook SDK as module dependency

I am using facebook-android-sdk-4.3.0. I have error after following steps of this solution Android Studio 0.8.1 - how to use Facebook SDK?
M:\Myapp\app\build\intermediates\res\debug\drawable-xhdpi\com_facebook_button_send_icon.png: error: Duplicate file.
M:\Myapp\app\build\intermediates\res\debug\drawable-xhdpi-v4\com_facebook_button_send_icon.png: Original is here. The version qualifier may be implied.
Error:Execution failed for task ':app:processDebugResources'.
com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Users\saty\AppData\Local\Android\sdk\build-tools\21.1.2\aapt.exe'' finished with non-zero exit value 1
Please suggest me how to solve this problem?
Thanks in advance.
I solved my problem after following tutorial
https://trinitytuts.com/integrating-facebook-sdk-application-android-studio/
might be helpful for someone else.

Resources