Skip to content

[None][test] Stabilize scaffolding OpenAI worker tests#16853

Draft
Mgluhovskoi wants to merge 1 commit into
NVIDIA:mainfrom
Mgluhovskoi:agent/fix-scaffolding-worker-timeout
Draft

[None][test] Stabilize scaffolding OpenAI worker tests#16853
Mgluhovskoi wants to merge 1 commit into
NVIDIA:mainfrom
Mgluhovskoi:agent/fix-scaffolding-worker-timeout

Conversation

@Mgluhovskoi

Copy link
Copy Markdown
Contributor

What changed

  • Bound the scaffolding OpenAI generation test to 100 output tokens.
  • Move the module-scoped server teardown into its pytest fixture.
  • Stop an individual test failure from terminating the server shared with the chat test.

Why

GenerationTask.create_from_prompt() leaves max_tokens unset. In a recent CI failure, the gpt-oss-20b request was accepted but continued until the OpenAI client's 600-second timeout. The failure handler then terminated the module-scoped server, causing the following chat test to fail against the same dead server.

Bounding the request matches the existing chat test and keeps this test focused on verifying successful worker generation. Fixture-owned teardown preserves pytest fail-fast behavior while preventing cascading failures and ensuring cleanup after the module.

Impact

Test-only change. Production behavior is unaffected.

Validation

  • python3 -m py_compile tests/unittest/scaffolding/test_worker.py
  • Formatting, codespell, legacy Ruff, and repository configuration pre-commit hooks passed.
  • Test-list duplicate and AST validation checks passed under Python 3.12.

The model-backed test requires the TensorRT-LLM GPU CI environment and was not run locally.

Signed-off-by: Maxim Gluhovskoi <mgluhovskoi@nvidia.com>
@Mgluhovskoi

Copy link
Copy Markdown
Contributor Author

/bot run

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61653 [ run ] triggered by Bot. Commit: ca6698f Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61653 [ run ] completed with state SUCCESS. Commit: ca6698f
/LLM/main/L0_MergeRequest_PR pipeline #49859 completed with status: 'SUCCESS'

CI Report

Link to invocation

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.

2 participants