Skip to content

Commit

Permalink
handle error
Browse files Browse the repository at this point in the history
  • Loading branch information
Signorini committed Mar 30, 2020
1 parent 7809c46 commit 72f7e5f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions app/libs/jsonEncoder.py
Expand Up @@ -15,6 +15,8 @@ def default(self, obj):
if isinstance(obj, datetime.datetime):
return obj.isoformat()

print("============================================================================ >", type(obj))
try:
return json.JSONEncoder.default(self, obj)
except TypeError as error:
logger.error(str(error))

return json.JSONEncoder.default(self, obj)
2 changes: 1 addition & 1 deletion requirements.txt
@@ -1,5 +1,5 @@
dnspython==1.16.0
boto3==1.12.30
boto3==1.12.32
celery==4.4.2
Flask==1.1.1
Flask-RESTful==0.3.8
Expand Down

0 comments on commit 72f7e5f

Please sign in to comment.