Skip to content

Commit cd9eed5

Browse files
committed
Upgrade black and other test dependencies
1 parent 0a55e2a commit cd9eed5

File tree

4 files changed

+11
-7
lines changed

4 files changed

+11
-7
lines changed

.github/workflows/pytype.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
pip install -e ".[testing]"
2525
pip install -e ".[optional]"
2626
# As pytype can change its behavior in newer versions, we manually upgrade it
27-
pip install "pytype==2022.1.13"
27+
pip install "pytype==2022.1.31"
2828
- name: Run pytype
2929
run: |
3030
pytype slack_sdk/

integration_tests/audit_logs/test_pagination.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,11 @@ def test_pagination(self):
2222
response = None
2323
ids = []
2424
while call_count < 10 and (response is None or response.status_code != 429):
25-
cursor = response.body["response_metadata"]["next_cursor"] if response is not None else None
25+
cursor = (
26+
response.body["response_metadata"]["next_cursor"]
27+
if response is not None
28+
else None
29+
)
2630
response = self.client.logs(action="user_login", limit=1, cursor=cursor)
2731
ids += map(lambda v: v["id"], response.body.get("entries", []))
2832
call_count += 1

setup.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,16 @@
2525
"pytest-cov>=2,<3",
2626
"codecov>=2,<3",
2727
"flake8>=4,<5",
28-
"black==21.12b0",
28+
"black==22.1.0",
2929
"psutil>=5,<6",
30-
"databases>=0.3",
30+
"databases>=0.5",
3131
# used only under slack_sdk/*_store
3232
"boto3<=2",
3333
# TODO: Upgrade to v2
34-
"moto<2", # For AWS tests
34+
"moto>=3,<4", # For AWS tests
3535
]
3636
codegen_dependencies = [
37-
"black==21.12b0",
37+
"black==22.1.0",
3838
]
3939

4040
needs_pytest = {"pytest", "test", "ptr"}.intersection(sys.argv)

slack_sdk/rtm/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -574,7 +574,7 @@ async def _wait_exponentially(self, exception, max_wait_time=300):
574574
if hasattr(exception, "response"):
575575
wait_time = exception.response.get("headers", {}).get(
576576
"Retry-After",
577-
min((2 ** self._connection_attempts) + random.random(), max_wait_time),
577+
min((2**self._connection_attempts) + random.random(), max_wait_time),
578578
)
579579
self._logger.debug("Waiting %s seconds before reconnecting.", wait_time)
580580
await asyncio.sleep(float(wait_time))

0 commit comments

Comments
 (0)