I have a problem on build android stand alone. it return an error message as below
[stderr] FAILURE: Build failed with an exception.
[stderr] * What went wrong:
[stderr] Execution failed for task ‘:app:mergeReleaseResources’.
[stderr] > java.util.concurrent.ExecutionException: com.android.builder.internal.aapt.v2.Aapt2Exception: Android resource compilation failed
[stderr] /app/turtle/workingdir/android/sdk33/android-shell-app/app/src/main/res/drawable-mdpi/shell_launch_background_image.png: error: failed to read PNG signature: file does not start with PNG signature.
[stderr] * Try:
[stderr] 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.
[stderr] * Get more help at https://help.gradle.org
[stderr] BUILD FAILED in 1m 27s
I’ve tried export my splash PNG file using multiple different software and non of them work. I am 100% sure it is a PNG not JPG image.
I’ve also tried to remove splash settings from app.json and it will build without any problem.
You can see the build error logs here
https://expo.io/builds/80b702bf-c7ef-4b43-9183-0d97276259b4
My app.json file and png image also attached. Also hint to solve this problem will be much appreciate.
{
“expo”: {
“name”: “Volleyball NZ”,
“description”: “Volleyball NZ”,
“slug”: “XXXXXXX”,
“privacy”: “unlisted”,
“sdkVersion”: “33.0.0”,
“platforms”: [“ios”, “android”,“web”],
“version”: “1.0.6”,
“orientation”: “portrait”,
“scheme”: “XXXXX”,
“icon”: “./assets/icons/app-icon.png”,
“splash”: {
“image”: “./assets/splash.png”,
“resizeMode”: “contain”,
“backgroundColor”: “#fff”
},
“updates”: {
“enabled”: false,
“checkAutomatically”: “ON_ERROR_RECOVERY”,
“fallbackToCacheTimeout”: 0
},
“assetBundlePatterns”: [
“assets/"
],
“ios”: {
“supportsTablet”: false,
“buildNumber”: “104”,
“bundleIdentifier”: “com.maxgen.volleyballnz”,
“icon”: “./assets/icons/app-icon.png”,
“splash”: {
“resizeMode”: “cover”,
“backgroundColor”: “#ef4823”,
“image”: “./assets/splash.png”,
}
},
“android”: {
“package”: “com.maxgen.volleyballnz”,
“versionCode”: 104,
“icon”: “./assets/icons/app-icon.png”,
“permissions”: [
“READ_INTERNAL_STORAGE”,
“VIBRATE”,
“com.google.android.c2dm.permission.RECEIVE”
],
},
“androidStatusBar”: {
“barStyle”: “light-content”,
“backgroundColor”: “#000000”
},
“assetBundlePatterns”: [
"assets/”
]
}
}