Closed RadoslawGlebicki closed 4 months ago
ok. i did:
buildozer android clean
and compilation went to another problem with gradlew.
After read the problem was with java.
in home dir del: .gradlew
play as root with:
alternatives --config java
I have 4 versions of java 8,11,21 and 22.
Now works with 21.
Hello, I encountered the same error as you, but running buildozer android clean
still gives this error.😢
I also solved it!
For the first error, I switched to the directory, for example, /home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/
, deleted the venv
directory, and manually ranpython3 -m venv venv
in this directory.
For the second error, I tried Java 8, 11, and 22, none of which worked. I succeeded with Java 17.
Versions
Description
try to compile main.py to apk in new system Fedora 40 Small test of main. After: .buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/hostpython3/desktop/hostpython3/native-build/python3 -m venv venv I get:
Ignoring "sys._home = value" override Ignoring "sys._home = value" override Traceback (most recent call last): File "", line 576, in _get_decompress_func
ModuleNotFoundError: No module named 'zlib' <- Here is something wrong? zlib-ng zlib-ng-devel (compat) installed
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "", line 624, in _get_data
File "", line 579, in _get_decompress_func
zipimport.ZipImportError: can't decompress data; zlib not available
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "", line 6, in
File "", line 222, in run_module
File "", line 148, in _get_module_details
File "", line 112, in _get_module_details
File "", line 195, in get_code
File "", line 758, in _get_module_code
File "", line 626, in _get_data
zipimport.ZipImportError: can't decompress data; zlib not available
Traceback (most recent call last):
File "", line 198, in _run_module_as_main
File "", line 88, in _run_code
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/hostpython3/desktop/hostpython3/Lib/ensurepip/main.py", line 5, in
sys.exit(ensurepip._main())
^^^^^^^^^^^^^^^^^
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/hostpython3/desktop/hostpython3/Lib/ensurepip/init.py", line 286, in _main
return _bootstrap(
^^^^^^^^^^^
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/hostpython3/desktop/hostpython3/Lib/ensurepip/init.py", line 202, in _bootstrap
return _run_pip([args, _PACKAGE_NAMES], additional_paths)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/hostpython3/desktop/hostpython3/Lib/ensurepip/init.py", line 103, in _run_pip
return subprocess.run(cmd, check=True).returncode
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/hostpython3/desktop/hostpython3/Lib/subprocess.py", line 571, in run
raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8aarmeabi-v7a/build/venv/bin/python3', '-W', 'ignore::DeprecationWarning', '-c', '\nimport runpy\nimport sys\nsys.path = [\'/tmp/tmpw06z9y9/setuptools-65.5.0-py3-none-any.whl\', \'/tmp/tmpw06z9y9/pip-23.2.1-py3-none-any.whl\'] + sys.path\nsys.argv[1:] = [\'install\', \'--no-cache-dir\', \'--no-index\', \'--find-links\', \'/tmp/tmpw06z9y9\', \'--upgrade\', \'setuptools\', \'pip\']\nrunpy.run_module("pip", run_name="main", alter_sys=True)\n']' returned non-zero exit status 1.
buildozer.spec
Command:
Spec file:
Logs
[DEBUG]: -> running python3 -m venv venv [DEBUG]: Error: Command '['/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/venv/bin/python3', '-m', 'ensurepip', '--upgrade', '--default-pip']' returned non-zero exit status 1. Exception in thread background thread for pid 220616: Traceback (most recent call last): File "/usr/lib64/python3.12/threading.py", line 1073, in _bootstrap_inner self.run() File "/usr/lib64/python3.12/threading.py", line 1010, in run self._target(*self._args, *self._kwargs) File "/home/radek/.local/lib/python3.12/site-packages/sh.py", line 1641, in wrap fn(rgs, **kwargs) File "/home/radek/.local/lib/python3.12/site-packages/sh.py", line 2569, in background_thread handle_exit_code(exit_code) File "/home/radek/.local/lib/python3.12/site-packages/sh.py", line 2269, in fn return self.command.handle_command_exit_code(exit_code) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/radek/.local/lib/python3.12/site-packages/sh.py", line 869, in handle_command_exit_code raise exc sh.ErrorReturnCode_1:
RAN: /home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/hostpython3/desktop/hostpython3/native-build/python3 -m venv venv
STDOUT: Error: Command '['/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/venv/bin/python3', '-m', 'ensurepip', '--upgrade', '--default-pip']' returned non-zero exit status 1.
STDERR:
Traceback (most recent call last): File "", line 198, in _run_module_as_main
File "", line 88, in _run_code
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 1256, in
main()
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/python-for-android/pythonforandroid/entrypoints.py", line 18, in main
ToolchainCL()
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 685, in init
getattr(self, command)(args)
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 104, in wrapper_func
build_dist_from_args(ctx, dist, args)
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 163, in build_dist_from_args
build_recipes(build_order, python_modules, ctx,
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/python-for-android/pythonforandroid/build.py", line 528, in build_recipes
run_pymodules_install(
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/python-for-android/pythonforandroid/build.py", line 701, in run_pymodules_install
shprint(host_python, '-m', 'venv', 'venv')
File "/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/python-for-android/pythonforandroid/logger.py", line 167, in shprint
for line in output:
File "/home/radek/.local/lib/python3.12/site-packages/sh.py", line 915, in next
self.wait()
File "/home/radek/.local/lib/python3.12/site-packages/sh.py", line 845, in wait
self.handle_command_exit_code(exit_code)
File "/home/radek/.local/lib/python3.12/site-packages/sh.py", line 869, in handle_command_exit_code
raise exc
sh.ErrorReturnCode_1:
RAN: /home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/hostpython3/desktop/hostpython3/native-build/python3 -m venv venv
STDOUT: Error: Command '['/home/radek/Dokumenty/python/calcNotesForBuildozer/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/venv/bin/python3', '-m', 'ensurepip', '--upgrade', '--default-pip']' returned non-zero exit status 1.
STDERR: *** this from me below like always in red ****
Command failed: ['/usr/bin/python3'