Skip to content

Commit 2e43b7a

Browse files
committed
Update _requests.py
1 parent 92d9f75 commit 2e43b7a

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

dank_mids/_requests.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1503,10 +1503,12 @@ def adjust_batch_size(self) -> bool:
15031503
return self.controller.reduce_multicall_size(num_calls)
15041504
else:
15051505
_log_checking_batch_size("json", "requests", len(self))
1506-
_log_devhint(
1507-
"We still need some better logic for catching these errors and using them to better optimize the batching process"
1508-
)
1509-
return self.controller.reduce_batch_size(len(self))
1506+
try:
1507+
return self.controller.reduce_batch_size(len(self))
1508+
finally:
1509+
_log_devhint(
1510+
"We still need some better logic for catching these errors and using them to better optimize the batching process"
1511+
)
15101512

15111513

15121514
# NOTE: These errors are expected during normal use and are not indicative of any problem(s). No need to log them.

0 commit comments

Comments
 (0)