Add the fault handler in order to try to get a proper crash stack

This commit is contained in:
Julien Duponchelle committed 2015-05-17 12:47:04 +02:00
1 parent 221a35baae
commit 0c5b753211
2 files changed
+6

No files matched your search

+4
View File
@@ -19,6 +19,10 @@ import os
import sys
import struct
import platform
import faulthandler
# Display a traceback in case of segfault crash. Usefull when frozen
faulthandler.enable()
try:
import raven
+2
View File
@@ -190,6 +190,8 @@ def main():
port = int(server_config["port"])
server = Server.instance(host, port)
try:
import faulthandler
faulthandler._sigsegv()
server.run()
except OSError as e:
# This is to ignore OSError: [WinError 0] The operation completed successfully exception on Windows.