Skip to content

The agent that grows with you

fix(skills_hub): clawhub 429 keeps a zero Retry-After as zero

teknium1db5827e3d24b
diff --git a/tools/skills_hub_clawhub.py b/tools/skills_hub_clawhub.py
index 6acd733f350..2d63f5be2e3 100644
--- a/tools/skills_hub_clawhub.py
+++ b/tools/skills_hub_clawhub.py
@@ -491,7 +491,8 @@ class ClawHubSource(GuardedFetchMixin, SkillSource):
if resp is None:
return files
if resp.status_code == 429:
- retry_after = max(0, min(int(parse_retry_after_seconds(resp.headers) or 5), 15)) # Cap wait time
+ parsed = parse_retry_after_seconds(resp.headers)
+ retry_after = min(int(5 if parsed is None else parsed), 15) # Cap wait time
logger.debug(
"ClawHub download rate-limited for %s, retrying in %ds (attempt %d/%d)",
slug, retry_after, attempt + 1, max_retries,