Skip to content

Commit 3d7f305

Browse files
committed
fix: add type ignore comments for chat_stream args delegated to the API
1 parent 0195ee2 commit 3d7f305

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

slack_bolt/agent/agent.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,10 @@ def chat_stream(
6363
raise ValueError(
6464
"Either provide all of channel, thread_ts, recipient_team_id, and recipient_user_id, or none of them"
6565
)
66+
# Argument validation is delegated to chat_stream() and the API
6667
return self._client.chat_stream(
67-
channel=channel or self._channel_id,
68-
thread_ts=thread_ts or self._thread_ts,
68+
channel=channel or self._channel_id, # type: ignore[arg-type]
69+
thread_ts=thread_ts or self._thread_ts, # type: ignore[arg-type]
6970
recipient_team_id=recipient_team_id or self._team_id,
7071
recipient_user_id=recipient_user_id or self._user_id,
7172
**kwargs,

slack_bolt/agent/async_agent.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,10 @@ async def chat_stream(
6060
raise ValueError(
6161
"Either provide all of channel, thread_ts, recipient_team_id, and recipient_user_id, or none of them"
6262
)
63+
# Argument validation is delegated to chat_stream() and the API
6364
return await self._client.chat_stream(
64-
channel=channel or self._channel_id,
65-
thread_ts=thread_ts or self._thread_ts,
65+
channel=channel or self._channel_id, # type: ignore[arg-type]
66+
thread_ts=thread_ts or self._thread_ts, # type: ignore[arg-type]
6667
recipient_team_id=recipient_team_id or self._team_id,
6768
recipient_user_id=recipient_user_id or self._user_id,
6869
**kwargs,

0 commit comments

Comments
 (0)