Author name: gk

File manager with search and sort option for Kivy and Kivymd

File manager with search and sort option for Kivy and Kivymd

while Kivy file manager and KivyMD file manager exist, they lack in their functionality as listed below. Hence the existing KivyMD file manager is customised to have search and sort option to access any file quickly. This post explains the working of the modified file manager. You can download the code of the modified Kivymd […]

File manager with search and sort option for Kivy and Kivymd Read More »

How to convert python code to exe and apk for Linux, Android, Windows, Raspberry Pi and Libre computer

Convert Python code to Exe and APK for Linux, Android, Windows, Raspberry Pi, and Libre computer

Are you looking to convert your Python code or python project to an executable for Linux, Android, Windows, Raspberry Pi or Libre Computer. You have reached the right place. We will convert the python code to executable that will work in all these different operating systems. Why to convert python code to executable When you

Convert Python code to Exe and APK for Linux, Android, Windows, Raspberry Pi, and Libre computer Read More »

Python GUI project - Free Image to PDF converter

Python GUI project – Image to PDF converter

This post has all of a useful Python GUI project with source code and executable. This project can be considered as a Python GUI example. The source code is converted to executable for Linux, Android, Windows, Raspberry Pi pc and Libre Computer. You can use the source code to study this as a python GUI

Python GUI project – Image to PDF converter Read More »

How to read and write to external storage in latest android API>29 from Kivy python

How to read and write to external storage in latest android API>29 from Kivy python

Latest development in Android needs significant modifications in the way we seek permissions to read and write files in the external storage of android. Old method of seeking android.permission.READ_EXTERNAL_STORAGE and android.permission.WRITE_EXTERNAL_STORAGE will not work any more. Lets see the reason and the possible work around to resolve this in this post. The Python code with

How to read and write to external storage in latest android API>29 from Kivy python Read More »

How to solve hunks FAILED -- saving rejects to file

How to solve hunks FAILED — saving rejects to file

During the building of android app from python code you may come across this error RAN: /usr/bin/patch -t -d /home/gk/.local/share/python-for-android/build/other_builds/opencv/arm64-v8a__ndk_target_24/opencv -p1 -i /home/gk/.local/lib/python3.11/site-packages/pythonforandroid/recipes/opencv/patches/p4a_build.patch STDOUT: patching file cmake/OpenCVDetectPython.cmake Hunk #1 FAILED at 175. Hunk #2 FAILED at 244. 2 out of 2 hunks FAILED — saving rejects to file cmake/OpenCVDetectPython.cmake.rej patching file modules/python/CMakeLists.txt What does the

How to solve hunks FAILED — saving rejects to file Read More »

How to solve Running cythonize failed in python for android or buildozer

How to solve Running cythonize failed in python for android or buildozer

The error Running cythonize failed can be a outcome when the numpy version you are building is not suitable for the python interpreter you are packaging. This can happen when you use Python for android and Buildozer. Error output Following is the error output Error compiling Cython file: ———————————————————— … self.rng_state.ctr.v[i] = counter[i] self._reset_state_variables() self._bitgen.state

How to solve Running cythonize failed in python for android or buildozer Read More »

How to solve destination path external jpeg' already exists and is not an empty directory.

How to solve destination path ‘external/jpeg’ already exists and is not an empty directory.

Some times you may get the following error while building an android app from python code RAN: /home/gk/.local/share/python-for-android/build/bootstrap_builds/sdl2/jni/SDL2_image/external/download.sh STDOUT: fatal: destination path ‘external/jpeg’ already exists and is not an empty directory. This can be resolved by cleaning the build in both python for android p4a or buildozer by executing the following commands p4aclean-dists p4aclean_download_cache p4aclean_builds

How to solve destination path ‘external/jpeg’ already exists and is not an empty directory. Read More »

Resolve No module named math during building app in python for android or buildozer

Solve No module named math during building app in python for android or buildozer

While building an Python based android app you may encounter the following error [2m< from random import Random as _Random[0m [2m< File “/home/gk/.local/share/python-for- android/build/other_builds/hostpython3/desktop/hostpython3/Lib/random.py”, line 49, in <module>[0m [2m< from math import log as _log, exp as _exp, pi as _pi, e as _e, ceil as _ceil[0m [2m< ModuleNotFoundError: No module named ‘math’[0m[2m[0m This is

Solve No module named math during building app in python for android or buildozer Read More »

KivyMD recipe for python for android and buildozer

KivyMD recipe for python for android and buildozer

Why this kivyMD recipe After the development of the app in Python, Kivy  and  KivyMD, eventually, you would want to convert the python code to an android app. For this step, you need to add kivyMD as a requirements in Python for android or Buildozer. KivyMD has undergone a major change recently. The kivyMD mentioned

KivyMD recipe for python for android and buildozer Read More »

How to convert python code to an android app in 5 steps

Python to android App in 5 steps

Here are the 5 steps to convert your python code to an android apk Write and test your python code in desktop pc Run the following command p4a apk –private [dir location] –package org.techris.kmd –name “Custom name” –version 24.05.10 –bootstrap sdl2 –requirements python3==3.11.2,kivy,kivymd –sdk-dir [SDK installation location] –ndk-dir [ndk installation location] –android-api 34 –ndk-api 24

Python to android App in 5 steps Read More »

Scroll to Top