Skip to content

fix(endpoint): honor the default async output timeout - #662

Open
feiiiiii5 wants to merge 1 commit into
runpod:mainfrom
feiiiiii5:codex/async-output-default-timeout
Open

feiiiiii5 wants to merge 1 commit into
runpod:mainfrom
feiiiiii5:codex/async-output-default-timeout

Conversation

@feiiiiii5

Copy link
Copy Markdown

await job.output() on a fresh asynchronous job immediately raises TimeoutError: Job timed out. before making a status request. The default timeout=0 is passed directly to asyncio.wait_for, although the public example calls this method without a timeout and the synchronous API treats zero as no deadline.

Map zero to None for the wait. Explicit positive deadlines and cached outputs keep their existing behavior.

The new regression uses the public Job.output() path with status responses progressing from IN_PROGRESS to COMPLETED. It fails on main with TimeoutError; after the one-line fix, all 50 endpoint tests pass on Python 3.12.8, including the existing positive-timeout tests.

Validation: pytest tests/test_endpoint -o addopts= --no-cov --timeout=30 -q; Python compilation; Black checks for the changed method and test. The production file has existing whitespace formatting findings on main as well; those are unchanged. Full repository coverage was not run.

This branch has not been deployed

No deployments
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