Refactored the way messages are processed. Added new raffle.
Showing
4 changed files
with
6 additions
and
1 deletions
1 | import operator | ||
1 | import sqlite3 | 2 | import sqlite3 |
3 | import datetime | ||
2 | 4 | ||
3 | conn = sqlite3.connect('db.sqlite3') | 5 | conn = sqlite3.connect('db.sqlite3') |
4 | 6 | ||
5 | def log(message): | 7 | def log(message): |
6 | logging.warning("{} - {}".format(datetime.datetime.now().strftime('%Y/%m/%d %H:%M:%S'), message)) | 8 | try: |
9 | logging.warning("{} - {}".format(datetime.datetime.now().strftime('%Y/%m/%d %H:%M:%S'), message)) | ||
10 | except: | ||
11 | pass | ||
7 | 12 | ||
8 | ################## | 13 | ################## |
9 | ## Database Calls | 14 | ## Database Calls | ... | ... |
No preview for this file type
This diff is collapsed.
Click to expand it.
This diff is collapsed.
Click to expand it.
-
Please register or sign in to post a comment