Nisarg
Nisarg

Reputation: 473

kivy & plyer Notification Error

I am trying to give notification in android app made in kivy as follow:

from plyer import notification

notification.notify('test tiltle','scanning started')

but i am getting this error in logcat each time

chnhack/in/web_sqli/R$drawable'
I/python  (28327):  Exception in thread Thread-1:
I/python  (28327):  Traceback (most recent call last):
I/python  (28327):    File "/root/.buildozer/android/platform/python-for-android/build/python-install/lib/python2.7/threading.py", line 552, in __bootstrap_inner
I/python  (28327):    File "/root/.buildozer/android/app/main.py", line 165, in run
I/python  (28327):    File "/root/.buildozer/android/platform/python-for-android/build/python-install/lib/python2.7/site-packages/plyer/facades/notification.py", line 21, in notify
I/python  (28327):    File "/root/.buildozer/android/platform/python-for-android/build/python-install/lib/python2.7/site-packages/plyer/facades/notification.py", line 26, in _notify
I/python  (28327):  NotImplementedError: No usable implementation found!
I/python  (28327):  
D/dalvikvm(28327): threadid=11: thread exiting, not yet detached (count=0)
D/dalvikvm(28327): threadid=11: thread exiting, not yet detached (count

It would be great if anyone help me

Upvotes: 0

Views: 2722

Answers (1)

Peter Badida
Peter Badida

Reputation: 12189

Reading this example and actual code for notification solves your problem. notify() expects to pass kwargs: icon_android, title, message

notification.notify(title: 'test tiltle',message: 'scanning started')

For similar problems use something more real-time to ask, the best for now is the IRC.

Upvotes: 1

Related Questions