I am new to Fastlane and want to build my apk through the Fastlane and Gitlab. I have been getting this error whenever I run the Fastlane command:
FAILURE: Build failed with an exception.
* Where:
Build file '/builds/sw/pro/pro_app_flutter/android/app/build.gradle' line: 30
* What went wrong:
A problem occurred evaluating project ':app'.
> Could not read script '/Users/your-user/Library/Android/flutter/packages/flutter_tools/gradle/flutter.gradle' as it does not exist.
But I am unable to figure this out, what does this mean because flutter.gradle does exist on the path!
Moreover the build from Android Studio is successfully generated!
Thanks in advance
P.S my fast file:
default_platform(:android)
platform :android do
desc "Build a Flutter apk1"
lane :buildDebug do
gradle(task: "assemble", project_dir: 'android/')
end
end
Related
I try make a first app like in manual https://cordova.apache.org/docs/en/latest/guide/cli/index.html
but after command cordova build android
FAILURE: Build failed with an exception.
Where:
Settings file '/Users/roman2322/Desktop/cordova/7/hello/platforms/android/settings.gradle'
What went wrong:
Could not compile settings file '/Users/roman2322/Desktop/cordova/7/hello/platforms/android/settings.gradle'.
startup failed:
General error during conversion: Unsupported class file major version 62
I am creating release APK using the following versions : node - 8.12.0 gradle - 4.10.2 ionic CLI - 4.0.5 Cordova - 8.0.0
When I run the
ionic cordova build android --prod --release
I am getting the following error.
FAILURE: Build failed with an exception.
* Where:
Build file '/app/platforms/android/app/build.gradle' line: 94
* What went wrong:
A problem occurred evaluating project ':app'.
> Could not resolve all files for configuration 'classpath'.
> Could not find com.google.gms:google-services:3.2.0.
Searched in the following locations:
https://jcenter.bintray.com/com/google/gms/google-services/3.2.0/google-services-3.2.0.pom
https://jcenter.bintray.com/com/google/gms/google-services/3.2.0/google-services-3.2.0.jar
https://repo1.maven.org/maven2/com/google/gms/google-services/3.2.0/google-services-3.2.0.pom
https://repo1.maven.org/maven2/com/google/gms/google-services/3.2.0/google-services-3.2.0.jar
Today there is a problem with repositories. It seems no one can build a project Could not find com.google.gms:google-services:4.1.0
I'm trying to build an ionic app for Android but when I run
ionic cordova run android
I get
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:transformClassesWithDexBuilderForDebug'.
> com.android.build.api.transform.TransformException: java.lang.IllegalStateException: Dex archives: setting .DEX extension only for .CLASS files
Trying to run ./gradlew clean gets me
FAILURE: Build failed with an exception.
* What went wrong:
Could not create service of type ScriptPluginFactory using BuildScopeServices.createScriptPluginFactory().
> Could not create service of type FileHasher using BuildSessionScopeServices.createFileSnapshotter().
I had the same issue but it was resolved. Thanks to information from #notlose at this link https://github.com/oney/react-native-gcm-android/issues/32
Solution:
just remove both 'build' folder in /android and /android/app
and build again with
'react-native run-android' for react-native
'ionic cordova run android' for ionic
i install react native and open a new project.
i try to run
react-native run-android
and I get this error
PS E:\Projects\React native\myapp> react-native run-android
Scanning 574 folders for symlinks in E:\Projects\React native\myapp\node_modules (27ms)
JS server already running.
Building and installing the app on the device (cd android && gradlew.bat installDebug)...
FAILURE: Build failed with an exception.
* Where:
Build file 'E:\⌠°σΘΘ≈ΦΘφ\⌠°σΘΘ≈ΦΘφ ≈Θ⌡\React native\myapp\android\app\build.gradle' line: 1
* What went wrong:
A problem occurred evaluating project ':app'.
> Failed to apply plugin [id 'com.android.application']
> Your project path contains non-ASCII characters. This will most likely cause the build to fail on Windows. Please move your project to a different directory. See http://b.android.com/95744 for details. This warning can be disabled by adding the line 'android.overridePathCheck=true' to gradle.properties file in the project directory.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 2.877 secs
Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/android-setup.html
As you can see from the error you need to move your project to a different directory with no non-ASCII characters.
Your project path contains non-ASCII characters. This will most
likely cause the build to fail on Windows. Please move your project
to a different directory. See http://b.android.com/95744 for details
I am just beginning my work with React-Native. After initializing the directory for my project and starting react in one terminal, I use the command react-native run-android to start the emulator. The emulator fails with the error:
FAILURE: Build failed with an exception.
Where:
Build file 'C:\Users\dannyd1221\Desktop\School\CIS350\Weekdays\android\app\build.gradle' line: 110
What went wrong:
A problem occurred evaluating project ':app'.
Could not normalize path for file 'C:\Users\dannyd1221\Desktop\School\CIS350\Weekdays\android\C:Usersdannyd1221AppDataLocalAndroidSdk\tools\proguard\proguard-android.txt'.
Clearly the path to proguard-android.txt is incorrect, but I'm not sure where that path is being set. Any ideas as to how this can be fixed?
Had a similar error.
Worked when i Replaced
C:\Users\dannyd1221\Desktop\School\CIS350\Weekdays\android\
with
C:/Users/dannyd1221/Desktop/School/CIS350/Weekdays/android/