Use below code to send the desktop notification. As a software engineer, you can use this script to send a notification to desktop when your background running script reaches to its end or it throws an error that needs your attention.
import subprocess as s s.call(['notify-send','Execution of your python script has been finished.'])
Happy Coding!
Leave a Reply