brother_ql.web: print exceptions to stderr & listen @ public IPs
This commit is contained in:
@@ -153,6 +153,7 @@ def print_text(content=None):
|
|||||||
del be
|
del be
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
return_dict['message'] = str(e)
|
return_dict['message'] = str(e)
|
||||||
|
logger.warning('Exception happened: %s', e)
|
||||||
response.status = 500
|
response.status = 500
|
||||||
return return_dict
|
return return_dict
|
||||||
|
|
||||||
@@ -198,7 +199,7 @@ def main():
|
|||||||
sys.stderr.write('Could not find any of the default fonts')
|
sys.stderr.write('Could not find any of the default fonts')
|
||||||
sys.exit()
|
sys.exit()
|
||||||
|
|
||||||
run(host='localhost', port=args.port, debug=args.loglevel==logging.DEBUG)
|
run(host='', port=args.port, debug=args.loglevel==logging.DEBUG)
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
main()
|
main()
|
||||||
|
|||||||
Reference in New Issue
Block a user