A simple demo application for Android, in which the Plyer logic for sending notifications has been restored.
versionchanged:: 1.5.0
Fixed notifications. Changed getting activity depending on api_version >= 31.
Functon _set_icons has been refactored.
Added text style property for large message.
The app works 'as it is' with import from notification.py
Or you can put this file to the Plyer directory:
site-packages/plyer/platforms/android/notification.py
before build process (when buildozer downloads and sets up all the prerequisites for python-for-android, including the android SDK and NDK).
- Install Ubuntu WSL and follow Linux steps.
- Use ArtemSBulgakov/buildozer-action@v1 to build your packages automatically on push or pull request.
- See full workflow example.
Do not forget to run buildozer android clean or remove .buildozer directory before building if version was updated (Buildozer doesn't update already downloaded packages).
- https://github.com/nandanhere/kivyTimeTable/blob/main/replaceNotification.py
- https://github.com/orgs/kivy/discussions/20
- https://github.com/kivy/kivy/wiki/Background-Service-using-P4A-android.service
- https://stackoverflow.com/questions/46760144/kivy-and-android-notifications
I tested this app with api_version >= 31 and api_version < 31. It works for Android 14.