Skip to content

test: retry Maestro rate limits - #714

Draft
colll78 wants to merge 3 commits into
Anastasia-Labs:mainfrom
colll78:codex/maestro-429-retry
Draft

test: retry Maestro rate limits#714
colll78 wants to merge 3 commits into
Anastasia-Labs:mainfrom
colll78:codex/maestro-429-retry

Conversation

@colll78

@colll78 colll78 commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Summary

  • wrap fetch only for the credentialed Maestro provider integration suite
  • retry HTTP 429 responses at most three times while honoring numeric and HTTP-date Retry-After values
  • cap waits at 30 seconds and use capped exponential fallback delays when Retry-After is absent or malformed
  • preserve immediate behavior for non-429 responses, network errors, and test assertion failures
  • restore the original global fetch after the Maestro suite
  • skip live Blockfrost and Lucid preprod tests when their required credentials are unavailable while keeping deterministic tests active

Root cause

The generated Version Packages PR failed in the provider test task when Maestro rate-limited getDatum with HTTP 429. The existing live tests surfaced the response immediately even when Maestro supplied a retry window.

Failed run: https://github.com/Anastasia-Labs/lucid-evolution/actions/runs/29304106848/job/87014164280

This change is test-only and does not alter the published provider or application behavior.

The first two runs of this fork PR also exposed existing missing-secret failures. Fork workflows receive empty repository secrets, but the live Blockfrost provider suite and several Lucid preprod cases still attempted requests with an empty URL. The included guards require the exact credentials consumed by each network-dependent suite or case; deterministic provider, wallet, and transaction-hash coverage remains enabled.

Validation

  • focused retry suite: 7 passed
  • complete provider suite: 48 passed, 43 credential-dependent tests skipped
  • fork-equivalent provider suite with external secrets empty: 36 passed, 55 skipped
  • fork-equivalent Lucid suite with external secrets empty: 124 passed, 120 skipped
  • targeted strict TypeScript check for the provider changes: passed
  • repository build: 14 tasks passed
  • repository lint: 22 tasks passed
  • repository format check: passed
  • differential review: no actionable findings

The local environment did not contain a Maestro API key, so the live Maestro suite was skipped locally. Synthetic response coverage verifies both Retry-After forms, delay and retry bounds, fallback delays, non-429 pass-through, and thrown-error pass-through. The locally configured Blockfrost live suite still ran and passed after the credential gate was added.

No changeset is included because this modifies CI tests only.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant