Skip to content

[VDR][v0.6.0] TUT-63304da8 · Single-step tutorial's own unit test fails: output items now require a type discriminator #2695

Description

@anwithk

Severity: 🟠 high | Category: Tutorials | Finding ID: TUT-63304da8

Location: fern/versions/latest/pages/environment-tutorials/single-step-environment.mdx:386

Problem

Section 5 tells you to paste three tests into tests/test_app.py. test_verify_without_tool_call builds an output item {"role": "assistant", "id": "", "content": [...]} with no type key. NeMoGymResponse gained a validator at nemo_gym/openai_utils.py:535 in commit 88d1692 (2026-08-10, after v0.5.0) that rejects it. Copy-pasting the tutorial's code verbatim gives 1 failed, 2 passed — the doc's success criterion for step 5 is unreachable.

Suggested fix

Add "type": "message" (and "status": "completed") to the assistant output item in the snippet, matching the shape used in fern/versions/latest/pages/agent-server/remote-agent.mdx:165. Consider a docs test that executes the tutorial's snippets in CI so openai_utils schema changes can't silently break them.

Evidence

ValidationError for NeMoGymResponse / output.0 / Value error, Responses API output items must include a type discriminator -> 1 failed, 2 passed

Found by the tutorial-walker critic in DX review Gym-1-20260821203248 — incremental from v0.5.0 to fa0d25158. Parent tracker #2214.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status
    Dev WIP

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions