i'm new on python and pynotify i want to create a notify message that shows me a notification with python and pynotify but i have a problem, all examples i use on tutorials found on internet.
ex.
#!/usr/bin/python
import sys
import pynotify
if __name__ == "__main__":
if not pynotify.init("icon-summary-body"):
sys.exit(1)
n = pynotify.Notification(
"Hi There",
"welcome to stackoverflow!",
##dont remove the below line
"notification-message-im")
n.show()
or
#!/usr/bin/env python
import os
import pynotify
pynotify.init("random information")
s = os.popen("fortune -n 100 -s","r").read()
n = pynotify.Notification("Fortune",s)
n.show()
gives me always the same error
** (icmp.py:13188): WARNING **: Connection Closed
Traceback (most recent call last):
File "icmp.py", line 14, in <module>
n.show()
gio.Error: Connection Closed
What does it mean??
Thanks