From 66e54b06896a9de7b35d1700ad34b25778780408 Mon Sep 17 00:00:00 2001 From: Trygve Aaberge Date: Sat, 28 Jan 2023 19:29:00 +0100 Subject: Include options in HttpError --- slack/error.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'slack/error.py') diff --git a/slack/error.py b/slack/error.py index 8a8c1b9..17427f7 100644 --- a/slack/error.py +++ b/slack/error.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Mapping, Union +from typing import TYPE_CHECKING, Dict, Mapping, Union if TYPE_CHECKING: from slack_api.slack_error import SlackErrorResponse @@ -9,9 +9,17 @@ if TYPE_CHECKING: class HttpError(Exception): - def __init__(self, url: str, return_code: int, http_status_code: int, error: str): + def __init__( + self, + url: str, + options: Dict[str, str], + return_code: int, + http_status_code: int, + error: str, + ): super().__init__() self.url = url + self.options = options self.return_code = return_code self.http_status_code = http_status_code self.error = error -- cgit