added graceful exit

This commit is contained in:
Navan Chauhan 2020-08-04 23:12:03 +05:30
parent 3340d0f9f2
commit c3366e48e8
1 changed files with 4 additions and 0 deletions

View File

@ -7,6 +7,10 @@ sql_select_Query = "select * from curieweb where done=0 LIMIT 1"
mycursor.execute(sql_select_Query)
records = mycursor.fetchall()
if records == []:
print("Empty Set 😳")
print("No active task, exitting gracefully")
exit(0)
def email(zipArchive):
import smtplib