Skip to content

Commit 08b98d2

Browse files
authored
Retry More (Network) Exceptions (#1341)
* retry more (network) exceptions * write changelog
1 parent da1b6d9 commit 08b98d2

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

webknossos/Changelog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ For upgrade instructions, please check the respective _Breaking Changes_ section
3838
### Changed
3939
- Every file that sends logging messages has its own logger now. This can be used to selectively disable loggers. [#1335](https://github.com/scalableminds/webknossos-libs/pull/1335)
4040
- Enabled compression by default for `convert-zarr` and `convert-raw` CLI commands. [#1338](https://github.com/scalableminds/webknossos-libs/pull/1338)
41+
- Add more (network) errors ("UNAVAILABLE", "Unknown error") to list of retryable errors. [#1341](https://github.com/scalableminds/webknossos-libs/pull/1341)
4142

4243

4344
## [2.4.3](https://github.com/scalableminds/webknossos-libs/releases/tag/v2.4.3) - 2025-07-07

webknossos/webknossos/utils.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,12 @@
4343

4444
def _is_exception_retryable(exception: Exception) -> bool:
4545
exception_str_lower = str(exception).lower()
46-
if "too many requests" in exception_str_lower or "gateway" in exception_str_lower:
46+
if (
47+
"too many requests" in exception_str_lower
48+
or "gateway" in exception_str_lower
49+
or "unavailable" in exception_str_lower
50+
or "unknown error" in exception_str_lower
51+
):
4752
return True
4853
return False
4954

0 commit comments

Comments
 (0)