aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mitmproxy/exceptions.py24
1 files changed, 0 insertions, 24 deletions
diff --git a/mitmproxy/exceptions.py b/mitmproxy/exceptions.py
index 1bc23a24..c4797e21 100644
--- a/mitmproxy/exceptions.py
+++ b/mitmproxy/exceptions.py
@@ -7,9 +7,6 @@ See also: http://lucumr.pocoo.org/2014/10/16/on-error-handling/
"""
from __future__ import absolute_import, print_function, division
-import sys
-import traceback
-
class ProxyException(Exception):
@@ -78,27 +75,6 @@ class ReplayException(ProxyException):
pass
-class ScriptException(ProxyException):
-
- @classmethod
- def from_exception_context(cls, cut_tb=1):
- """
- Must be called while the current stack handles an exception.
-
- Args:
- cut_tb: remove N frames from the stack trace to hide internal calls.
- """
- exc_type, exc_value, exc_traceback = sys.exc_info()
-
- while cut_tb > 0:
- exc_traceback = exc_traceback.tb_next
- cut_tb -= 1
-
- tb = "".join(traceback.format_exception(exc_type, exc_value, exc_traceback))
-
- return cls(tb)
-
-
class FlowReadException(ProxyException):
pass