Repository navigation
[Test] Add a docs drift check for server_arguments.mdx - #38520
Conversation
|
/tag-and-rerun-ci |
|
Could you please fix the CPU test? |
Thanks @Kangyan-Zhou. The rebase of main introduced changes which caused the tests to fail. Fixed now. We will have to balance this with incoming changes that affect it until it lands. |
|
Thanks @ch-wan for the review. Updated and ready for review again. |
|
/tag-and-rerun-ci |
2f502bc to
5a9c9a1
Compare
ch-wan
left a comment
There was a problem hiding this comment.
Reviewed by agent.
Summary
This is a solid bookkeeping ratchet: it diffs the live ServerArgs argparse parser against server_arguments.mdx table rows, pins today’s 75 undocumented flags in a shrink-only allowlist, and cleans up the four stale rows so that allowlist is not carrying ghosts. Placement, CustomTestCase, register_cpu_ci, and the four test methods each guard a distinct failure mode (malformed rows, new gaps, stale allowlist entries, stale mentions). The remaining risk is operational: putting this one MDX path on main_package does run base-a-test-cpu, but it also dispatches the full NVIDIA GPU matrix and the run-ci gate for docs-only edits of that page.
Issue counts by severity
- bugs: 0
- suggestions: 1
- nits: 0
0271746 to
7349e2c
Compare
fd12441 to
56e688a
Compare
|
Thanks @ch-wan for the review and feedback. All three are addressed in the latest push. I took the count out of the description since it'd just go stale again. |
|
/rerun-test test_server_args_docs_coverage.py |
|
🚀 |
The docs drift check from sgl-project#38520 requires every live flag to have a row. Also rename the hook test whose name said the disabled-radix tree core is unused; since ChunkCache was removed, a disabled UnifiedRadixCache builds it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Post-rebase review fixes, squashed. Each corrects how one of our commits merged with an upstream v0.5.22 change. PD abort / deferred release (with upstream sgl-project#37077 generation protocol): - A receiver's clear() drops its own generation's ACK-tracker entry again. The merge dropped the token-scoped clear, so a receiver aborted before KV pre-allocation left a permanent tracker entry. - Keep a held room exclusive to its receiver under transfer drain (Mooncake), as the per-receiver token did locally: - a new receiver of a room its earlier receiver has not released fails fast before publishing any destination, leaving the room's status and failure record to the owner. Only the owner may resend the ABORT that drains the room, so a takeover would strand both receivers' buffers; - arm_deferred_abort_room() keeps the receiver's own generation and refuses to replace another undrained receiver's; - is_abort_release_safe()/clear_deferred_abort_state() take an optional generation; the decode release path passes the receiver's own. Upstream rejects a duplicate room only under prefill_complete; it can leave early mode alone because it force-releases on timeout, which fail-closed Mooncake does not. Non-drain backends keep upstream's semantics, and the wire format is unchanged. - Document that SGLANG_DISAGGREGATION_DECODE_BOOTSTRAP_TIMEOUT does not cover the prefill_complete wait. Drop lazy creation added during the rebase only so that tests built with __new__ would not raise AttributeError. Production always runs __init__, and the fallbacks would hide a missing initialization behind a fresh lock or table: CommonKVManager.connection_lock and the parallel-info tables are plain attributes set by __init__ / _init_decode_handshake_state() again, as upstream has them. _transfer_lifetime gets a declared class default instead of getattr lookups. trtllm_mla: pass forward_batch.kv_loc_plan, the first argument upstream (it raised TypeError on the first breakable prefill graph capture on SM100), and use paged_row_view for the KV buffer like upstream's call sites. cutedsl_mla fixed split-KV: allow FlashInfer 0.7.1, which upstream now pins. The adapter's private dependencies (cute_dsl_mla_decode, the _get_split_kv_and_workspace_size planner and the workspace layout) are unchanged from 0.6.18; 0.7.1 only adds lse_scale, whose default keeps the natural-log LSE. Without this, setting SGLANG_CUTEDSL_MLA_NUM_KV_SPLITS failed at startup. Docs: add --dcp-kv-layout, --max-parallel-samples and --max-batch-outputs to server_arguments.mdx, which upstream sgl-project#38520 now checks. Co-Authored-By: Claude <[email protected]>
…ad-back test_server_args_docs_coverage (added on main by sgl-project#38520) requires every live ServerArgs flag to have a row in server_arguments.mdx. Add rows for the two flags this PR introduces, using their help text. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ad-back test_server_args_docs_coverage (added on main by sgl-project#38520) requires every live ServerArgs flag to have a row in server_arguments.mdx. Add rows for the two flags this PR introduces, using their help text. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ad-back test_server_args_docs_coverage (added on main by sgl-project#38520) requires every live ServerArgs flag to have a row in server_arguments.mdx. Add rows for the two flags this PR introduces, using their help text. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Motivation
server_arguments.mdxdrifts from the CLI and the only fix today is someone noticing and hand editing a row. In the last three months, 5 PRs touched only this doc and 3 of them (#37989, #32172, #34654) just added rows for flags that had shipped without one. The same drift keeps getting found after the fact instead of being caught when the flag lands.Modifications
Adds
test/registered/unit/server_args/test_server_args_docs_coverage.py. It builds the realServerArgsargparse parser and diffs it against the doc tables. A live flag with no row in the Argument column fails and so does any flag the doc names that no longer registers as a current or deprecated flag.One allowlist,
server_arguments_undocumented.txt(beside the doc), lists the live flags that have no row today. It can only shrink. A new undocumented flag fails and an entry that gets documented or whose flag is removed has to come off the list. It sits outside themain_package pathsso a PR that backfills a row only runs the CPU stage.Also in this PR:
--speculative-use-block-verificationwith its CLI help text andFalsedefault, fixing the new docs coverage test without expanding the undocumented allowlist.--custom-sigquit-handler,--debug-tensor-dump-injectand--hybrid-kvcache-ratioare deleted.--hybrid-kvcache-ratiowas the only row under "Deprecated arguments", so that section is gone too.--optimistic-prefill-retriesis renamed to--optimistic-prefill-attempts, the flag's current name.server_args_docsfilter to_pr-test-check-changes.ymlthat only the CPU stage reads, like renderer. Otherwise a docs only PR skipsbase-a-test-cpu, can merge a stale row green and then breaks the test on main for everyone. It stays out ofmain_packageso a doc edit doesn't needrun-cior trigger the GPU stages.AI assistance was used for implementation and verification.
Accuracy Tests
N/A. Test, docs and CI filter only. No model or kernel code touched.
Speed Tests and Profiling
N/A, doesn't affect inference.
Checklist
speed.
CI States
Latest PR Test (Base): ⏳ Run #37744036367
Latest PR Test (Extra): ❌ Run #37744035808
Latest PR Test (AMD ROCm 10): ⏳ Run #37744036275