A new error from oven: gradlew bundleRelease

294 views
Skip to first unread message

berk berk

unread,
Aug 31, 2022, 8:47:23 PM8/31/22
to Kivy users support
Before i didn't get any 'gradlew' such a stuff error during release .aab file. but recently i got this error. 
Gradlew Failed 
gradlew bundleRelease

is there any solution?

Robert

unread,
Aug 31, 2022, 10:41:15 PM8/31/22
to Kivy users support
Almost certainly.

But you need to share the full log so we can see why Gradlew Failed.
Also tell us about your build environment, Buildozer version, stuff like that.

Throwing two lines over the wall and expecting a meaningful answer is wildly optimistic.

berk berk

unread,
Sep 1, 2022, 7:10:33 AM9/1/22
to Kivy users support
[INFO]:    Detected highest available build tools version to be 33.0.0-rc4
[DEBUG]:   -> running gradlew bundleRelease
[DEBUG]:        Starting a Gradle Daemon, 1 incompatible and 1 stopped Daemons could not be reused, use --status for detailsUG]:        > IDLE
[DEBUG]:
[DEBUG]:        > Configure project :
[DEBUG]:        WARNING: The option setting 'android.bundle.enableUncompressedNativeLibs=false' is experimental and unsupported.
[DEBUG]:        The current default is 'true'.
[DEBUG]:
[DEBUG]:
[DEBUG]:        > Task :stripReleaseDebugSymbols
[DEBUG]:        Support for ANDROID_NDK_HOME is deprecated and will be removed in the future. Use android.ndkVersion in build.gradle instead.
[DEBUG]:        /home/berk/.buildozer/android/platform/android-ndk-r19c/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-strip:/mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/build/intermediates/merged_native_libs/release/out/lib/armeabi-v7a/libpybundle.so: File format not recognized
[DEBUG]:
[DEBUG]:        Unable to strip library /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/build/intermediates/merged_native_libs/release/out/lib/armeabi-v7a/libpybundle.so due to error 1 returned from /home/berk/.buildozer/android/platform/android-ndk-r19c/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-strip, packaging it as is.
[DEBUG]:
[DEBUG]:        > Task :mergeReleaseResources FAILED
[DEBUG]:
[DEBUG]:        FAILURE: Build failed with an exception.
[DEBUG]:
[DEBUG]:        * What went wrong:
[DEBUG]:        Execution failed for task ':mergeReleaseResources'.
[DEBUG]:        > A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
[DEBUG]:           > Android resource compilation failed
[DEBUG]:             /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/src/main/res/mipmap/icon.png: AAPT: error: failed to read PNG signature: file does not start with PNG signature.
[DEBUG]:
[DEBUG]:             /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/src/main/res/mipmap/icon.png: AAPT: error: file failed to compile.
[DEBUG]:
[DEBUG]:
[DEBUG]:        * Try:
[DEBUG]:        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.
[DEBUG]:
[DEBUG]:        * Get more help at https://help.gradle.org
[DEBUG]:
[DEBUG]:        Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
[DEBUG]:        Use '--warning-mode all' to show the individual deprecation warnings.
[DEBUG]:        See https://docs.gradle.org/6.4.1/userguide/command_line_interface.html#sec:command_line_warnings
[DEBUG]:
[DEBUG]:        BUILD FAILED in 43s
[DEBUG]:        20 actionable tasks: 4 executed, 16 up-to-date

Exception in thread background thread for pid 128:
Traceback (most recent call last):
  File "/usr/lib/python3.8/threading.py", line 932, in _bootstrap_inner
    self.run()
  File "/usr/lib/python3.8/threading.py", line 870, in run
    self._target(*self._args, **self._kwargs)
  File "/home/berk/.local/lib/python3.8/site-packages/sh.py", line 1683, in wrap
    fn(*rgs, **kwargs)
  File "/home/berk/.local/lib/python3.8/site-packages/sh.py", line 2662, in background_thread
    handle_exit_code(exit_code)
  File "/home/berk/.local/lib/python3.8/site-packages/sh.py", line 2349, in fn
    return self.command.handle_command_exit_code(exit_code)
  File "/home/berk/.local/lib/python3.8/site-packages/sh.py", line 905, in handle_command_exit_code
    raise exc
sh.ErrorReturnCode_1:

  RAN: /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/gradlew bundleRelease

  STDOUT:
Starting a Gradle Daemon, 1 incompatible and 1 stopped Daemons could not be reused, use --status for details

> Configure project :
WARNING: The option setting 'android.bundle.enableUncompressedNativeLibs=false' is experimental and unsupported.
The current default is 'true'.


> Task :stripReleaseDebugSymbols
Support for ANDROID_NDK_HOME is deprecated and will be removed in the future. Use android.ndkVersion in build.gradle instead.
/home/berk/.buildozer/android/platform/android-ndk-r19c/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-strip:/mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/build/intermediates/merged_native_libs/release/out/lib/armeabi-v7a/libpybundle.so: File format not recognized

Unable to strip library /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/build/intermediates/merged_native_libs/release/out/lib/armeabi-v7a/libpybundle.so due to error 1 returned from /home/berk/.buildozer/android/platform/android-ndk-r19c/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-strip, packaging it as is.

> Task :mergeReleaseResources FAILED

FAILURE: Build failed with an exception.


* What went wrong:
Execution failed for task ':mergeReleaseResources'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
   > Android resource compilation failed
     /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/src/main/res/mipmap/icon.png: AAPT: error: failed to read PNG signature: file does not start with PNG signature.

     /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/src/main/res/mipmap/icon.png: AAPT: error: file failed to compile.


* 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

Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.4.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 43s
20 actionable tasks: 4 executed, 16 up-to-date


  STDERR:

WARNING: Received a --sdk argument, but this argument is deprecated and does nothing.
No setup.py/pyproject.toml used, copying full private data into .apk.
Applying Java source code patches...
Applying patch: src/patches/SDLActivity.java.patch
Warning: failed to apply patch (exit code 1), assuming it is already applied:  src/patches/SDLActivity.java.patch
[INFO]:    STDOUT (last 20 lines of 53):
             /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/src/main/res/mipmap/icon.png: AAPT: error: failed to read PNG signature: file does not start with PNG signature.

     /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/src/main/res/mipmap/icon.png: AAPT: error: file failed to compile.


* 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

Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.4.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 43s
20 actionable tasks: 4 executed, 16 up-to-date

[INFO]:    STDERR:

[INFO]:    ENV:
export LESSOPEN='| /usr/bin/lesspipe %s'
export P4A_RELEASE_KEYSTORE='/home/berk/keystores/mykey.keystore'
export USER='berk'
export SHLVL='1'
export P4A_RELEASE_KEYALIAS='myalias'
export HOME='/home/berk'
export ANDROIDMINAPI='21'
export WSL_DISTRO_NAME='Ubuntu-20.04'
export LOGNAME='berk'
export NAME='DESKTOP-J00DJ67'
export _='/home/berk/.local/bin/buildozer'
export ANDROIDAPI='30'
export P4A_RELEASE_KEYSTORE_PASSWD='*****'
export TERM='xterm-256color'
export ANDROIDNDK='/home/berk/.buildozer/android/platform/android-ndk-r19c'
export PATH='/home/berk/.buildozer/android/platform/android-ndk-r19c/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86/bin/:/home/berk/.buildozer/android/platform/android-ndk-r19c/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/:/home/berk/.buildozer/android/platform/android-ndk-r19c:/home/berk/.buildozer/android/platform/android-sdk/tools:/home/berk/.buildozer/android/platform/apache-ant-1.9.4/bin:/home/berk/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/mnt/c/Program Files (x86)/Common Files/Oracle/Java/javapath:/mnt/c/Windows/system32:/mnt/c/Windows:/mnt/c/Windows/System32/Wbem:/mnt/c/Windows/System32/WindowsPowerShell/v1.0/:/mnt/c/Windows/System32/OpenSSH/:/mnt/c/Program Files/dotnet/:/mnt/c/Program Files/Microsoft SQL Server/130/Tools/Binn/:/mnt/c/Program Files/Microsoft SQL Server/Client SDK/ODBC/170/Tools/Binn/:/mnt/c/Program Files (x86)/dotnet/:/mnt/c/Users/Berk/AppData/Local/Programs/Python/Python39/Scripts/:/mnt/c/Users/Berk/AppData/Local/Programs/Python/Python39/:/mnt/c/Program Files/Java/jdk1.8.0_271/bin:/mnt/c/Users/Berk/AppData/Local/Programs/MiKTeX/miktex/bin/x64/:/snap/bin'
export P4A_RELEASE_KEYALIAS_PASSWD='*****'
export LANG='C.UTF-8'
export ANDROIDSDK='/home/berk/.buildozer/android/platform/android-sdk'
export LS_COLORS='rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:'
export SHELL='/bin/bash'
export PACKAGES_PATH='/home/berk/.buildozer/android/packages'
export LESSCLOSE='/usr/bin/lesspipe %s %s'
export PWD='/mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/python-for-android'
export XDG_DATA_DIRS='/usr/local/share:/usr/share:/var/lib/snapd/desktop'
export HOSTTYPE='x86_64'
export WSLENV=''
export ANDROID_NDK_HOME='/home/berk/.buildozer/android/platform/android-ndk-r19c'
export ANDROID_HOME='/home/berk/.buildozer/android/platform/android-sdk'

[INFO]:    COMMAND:
cd /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app && /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/gradlew bundleRelease

[WARNING]: ERROR: /mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/gradlew failed!
# Command failed: /usr/bin/python3 -m pythonforandroid.toolchain aab --bootstrap sdl2 --dist_name my_app --name MORSe --version 1.1 --package org.my_app.my_app --minsdk 21 --ndk-api 21 --private /mnt/c/Users/Berk/Desktop/create/.buildozer/android/app --android-entrypoint org.kivy.android.PythonActivity --android-apptheme @android:style/Theme.NoTitleBar --presplash /mnt/c/Users/Berk/Desktop/create/intro.png --icon /mnt/c/Users/Berk/Desktop/create/icon.png --orientation portrait --window --release --sign --copy-libs --arch armeabi-v7a --color=always --storage-dir="/mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a" --ndk-api=21 --ignore-setup-py --debug
# ENVIRONMENT:
#     SHELL = '/bin/bash'
#     P4A_RELEASE_KEYSTORE_PASSWD = '*****'
#     WSL_DISTRO_NAME = 'Ubuntu-20.04'
#     P4A_RELEASE_KEYALIAS = 'myalias'
#     NAME = 'DESKTOP-J00DJ67'
#     PWD = '/mnt/c/Users/Berk/Desktop/create'
#     LOGNAME = 'berk'
#     P4A_RELEASE_KEYALIAS_PASSWD = '*****'
#     HOME = '/home/berk'
#     LANG = 'C.UTF-8'
#     LS_COLORS = 'rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:'
#     LESSCLOSE = '/usr/bin/lesspipe %s %s'
#     TERM = 'xterm-256color'
#     P4A_RELEASE_KEYSTORE = '/home/berk/keystores/mykey.keystore'
#     LESSOPEN = '| /usr/bin/lesspipe %s'
#     USER = 'berk'
#     SHLVL = '1'
#     WSLENV = ''
#     XDG_DATA_DIRS = '/usr/local/share:/usr/share:/var/lib/snapd/desktop'
#     PATH = ('/home/berk/.buildozer/android/platform/apache-ant-1.9.4/bin:/home/berk/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/mnt/c/Program '
 'Files (x86)/Common '
 'Files/Oracle/Java/javapath:/mnt/c/Windows/system32:/mnt/c/Windows:/mnt/c/Windows/System32/Wbem:/mnt/c/Windows/System32/WindowsPowerShell/v1.0/:/mnt/c/Windows/System32/OpenSSH/:/mnt/c/Program '
 'Files/dotnet/:/mnt/c/Program Files/Microsoft SQL '
 'Server/130/Tools/Binn/:/mnt/c/Program Files/Microsoft SQL Server/Client '
 'SDK/ODBC/170/Tools/Binn/:/mnt/c/Program Files '
 '(x86)/dotnet/:/mnt/c/Users/Berk/AppData/Local/Programs/Python/Python39/Scripts/:/mnt/c/Users/Berk/AppData/Local/Programs/Python/Python39/:/mnt/c/Program '
 'Files/Java/jdk1.8.0_271/bin:/mnt/c/Users/Berk/AppData/Local/Programs/MiKTeX/miktex/bin/x64/:/snap/bin')
#     HOSTTYPE = 'x86_64'
#     _ = '/home/berk/.local/bin/buildozer'
#     PACKAGES_PATH = '/home/berk/.buildozer/android/packages'
#     ANDROIDSDK = '/home/berk/.buildozer/android/platform/android-sdk'
#     ANDROIDNDK = '/home/berk/.buildozer/android/platform/android-ndk-r19c'
#     ANDROIDAPI = '30'
#     ANDROIDMINAPI = '21'
#
# Buildozer failed to execute the last command
# The error might be hidden in the log above this error
# Please read the full log, and search for it before
# raising an issue with buildozer itself.
# In case of a bug report, please add a full log with log_level = 2

1 Eylül 2022 Perşembe tarihinde saat 05:41:15 UTC+3 itibarıyla Robert şunları yazdı:

berk berk

unread,
Sep 1, 2022, 7:11:13 AM9/1/22
to Kivy users support
buildozer version 1.4.0
openjdk-13

1 Eylül 2022 Perşembe tarihinde saat 14:10:33 UTC+3 itibarıyla berk berk şunları yazdı:

Robert

unread,
Sep 1, 2022, 1:04:04 PM9/1/22
to Kivy users support
This is the error message:
 
/mnt/c/Users/Berk/Desktop/create/.buildozer/android/platform/build-armeabi-v7a/dists/my_app/src/main/res/mipmap/icon.png: AAPT: error: failed to read PNG signature: file does not start with PNG signature.

Also using WSL and building on a Windows partition can cause strange errors, copy the project to the WSL partition and build there.

berk berk

unread,
Sep 1, 2022, 3:54:34 PM9/1/22
to Kivy users support
Yeah i realized this point when i sent log file to group. But I did not sure actually, finally you said same point, i change my icon size to 97x97 it's solved.
*(i) my icon size was 512x512 
probably icon size must be =< 192x192 if your size less equal then 192x192 it does not give same problem.

Thanks
1 Eylül 2022 Perşembe tarihinde saat 20:04:04 UTC+3 itibarıyla Robert şunları yazdı:
Reply all
Reply to author
Forward
0 new messages