From d4a671d622cf558602debfee8396303986f92ac7 Mon Sep 17 00:00:00 2001 From: Trygve Aaberge Date: Wed, 8 Feb 2023 00:18:11 +0100 Subject: Add -data option to /slack debug error to print rtm event data --- slack/python_compatibility.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'slack/python_compatibility.py') diff --git a/slack/python_compatibility.py b/slack/python_compatibility.py index e96b8af..8aa8a84 100644 --- a/slack/python_compatibility.py +++ b/slack/python_compatibility.py @@ -18,5 +18,9 @@ def removesuffix(self: str, suffix: str) -> str: return self[:] +def format_exception_only(exc: BaseException) -> List[str]: + return traceback.format_exception_only(type(exc), exc) + + def format_exception(exc: BaseException) -> List[str]: return traceback.format_exception(type(exc), exc, exc.__traceback__) -- cgit