diff --git a/tools/skills_hub.py b/tools/skills_hub.py index d8408173183..db169b37d6d 100644 --- a/tools/skills_hub.py +++ b/tools/skills_hub.py @@ -909,12 +909,13 @@ class GitHubSource(SkillSource): def _download_directory_recursive(self, repo: str, path: str) -> Dict[str, str]: """Recursively download via Contents API (fallback).""" url = f"https://api.github.com/repos/{repo}/contents/{path.rstrip('/')}" - try: - resp = httpx.get(url, headers=self.auth.get_headers(), timeout=15, follow_redirects=True) - if resp.status_code != 200: - logger.debug("Contents API returned %d for %s/%s", resp.status_code, repo, path) - return {} - except httpx.HTTPError: + # Route through _github_get so directory listing gets the same + # 429/403-rate-limit retry + backoff as file fetches (#3033). + resp = self._github_get(url) + if resp is None: + return {} + if resp.status_code != 200: + logger.debug("Contents API returned %d for %s/%s", resp.status_code, repo, path) return {} entries = resp.json()