mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-09-14 18:01:20 +08:00
41352e927a
Render-time, post-hoc warning: when the slowest RenderChunk Lambda invocation burned through more than 80% of the 900-second cap, surface a warning at the end of --wait mode pointing at --max-parallel-chunks. The cost-analysis sweep hit this twice — inspector-launch at 1080p/60 and 4K@anything blew past the cap with default 16-way fan-out, producing a Sandbox.Timedout retry storm. The next user to push fps or duration on a heavy composition will hit the same wall; this turns a cryptic SFN failure into a one-line hint they can act on before the next render. Plumbing: - getRenderProgress tracks max billed-duration across RenderChunk invocations (the only state whose runtime is gated by the 15-min cap; Plan + Assemble are off-path). - RenderProgress.maxChunkDurationMs is null before the first chunk reports back. - LAMBDA_TIMEOUT_MS / CHUNK_RUNTIME_WARN_RATIO / CHUNK_RUNTIME_WARN_MS live in chunkRuntime.ts and are exported from the SDK so external callers (custom CLIs, monitoring) can match the threshold. - CLI's render --wait path prints the warning with a suggested --max-parallel-chunks value scaled by the observed headroom ratio. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>