Skip to content

Commit df3d5d6

Browse files
authored
Fix perform_bot_token_rotation call in AsyncInstallationStoreAuthorize (#825)
* Fix perform_bot_token_rotation call of AsyncTokenRotator * Fix pytype inconsistency in [Async]Listener
1 parent c99c23f commit df3d5d6

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

slack_bolt/authorization/async_authorize.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ async def __call__(
244244
raise BoltError(self._config_error_message)
245245
refreshed = await self.token_rotator.perform_bot_token_rotation(
246246
bot=bot,
247-
token_rotation_expiration_minutes=self.token_rotation_expiration_minutes,
247+
minutes_before_expiration=self.token_rotation_expiration_minutes,
248248
)
249249
if refreshed is not None:
250250
await self.installation_store.async_save_bot(refreshed)

slack_bolt/listener/async_listener.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ async def _next():
5757
return (resp, False)
5858

5959
@abstractmethod
60-
async def run_ack_function(self, *, request: AsyncBoltRequest, response: BoltResponse) -> BoltResponse:
60+
async def run_ack_function(self, *, request: AsyncBoltRequest, response: BoltResponse) -> Optional[BoltResponse]:
6161
"""Runs all the registered middleware and then run the listener function.
6262
6363
Args:

slack_bolt/listener/listener.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ def next_():
5555
return (resp, False)
5656

5757
@abstractmethod
58-
def run_ack_function(self, *, request: BoltRequest, response: BoltResponse) -> BoltResponse:
58+
def run_ack_function(self, *, request: BoltRequest, response: BoltResponse) -> Optional[BoltResponse]:
5959
"""Runs all the registered middleware and then run the listener function.
6060
6161
Args:

0 commit comments

Comments
 (0)