e.read() returns bytes
This commit is contained in:
parent
7e72cfd163
commit
887760acc1
1 changed files with 1 additions and 1 deletions
|
@ -100,7 +100,7 @@ class API(object):
|
|||
if self.DEBUG:
|
||||
import webbrowser
|
||||
if e.code >= 500:
|
||||
with open('/tmp/error.html', 'w') as f:
|
||||
with open('/tmp/error.html', 'wb') as f:
|
||||
f.write(e.read())
|
||||
webbrowser.open_new_tab('/tmp/error.html')
|
||||
|
||||
|
|
Loading…
Reference in a new issue