feat(cli): inline field docs in generated resources-server config (M6a)#1638
Merged
Merged
Conversation
db8b03c to
695207e
Compare
5e9d480 to
9bbd7f1
Compare
2905987 to
6ca5c48
Compare
The generated resources-server config's dataset comment referenced the deprecated gitlab_identifier/huggingface_identifier; point it at the unified source: block instead. Inline field documentation (friction #7) is already provided by the CLI scaffold; this PR is reduced to the source: alignment on top of it. Signed-off-by: Wojciech Prazuch <wprazuch@nvidia.com>
9bbd7f1 to
b6933fb
Compare
wprazuch
added a commit
that referenced
this pull request
Jun 25, 2026
…a) (#1638) ## What Generated resources-server configs (`ng_init_resources_server`) now carry inline comments explaining each non-obvious field — `domain`, `resources_server`, the `policy_model` magic name, and the `datasets`/`source:` block — so new users understand the scaffold without leaving the file. Addresses friction #7 (no inline documentation in generated configs). While here, the scaffold now emits the canonical `source:` dataset block instead of the deprecated `gitlab_identifier`, so a freshly created server starts on the recommended schema (depends on #1637). ## Notes - Chose inline comments over an indirected `FIELD_DOCS` constant (suggested in the RFC): there is a single generation site, so a one-line-per-field constant would add indirection without reuse. Easy to extract later if a second site appears. ## Tests - Extended `test_init_resources_server_includes_domain` to assert the generated config (a) contains the inline docs, (b) uses `source: {type: gitlab}` rather than `gitlab_identifier`, and (c) validates cleanly with no `DeprecationWarning`. Part of the configuration-friction epic (#1205), milestone M6a. Targets `wprazuch/dataset-source` since it builds on the `source:` schema; will retarget to the shared base once that merges. Signed-off-by: Wojciech Prazuch <wprazuch@nvidia.com>
This was referenced Jun 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Generated resources-server configs (
ng_init_resources_server) now carry inlinecomments explaining each non-obvious field —
domain,resources_server, thepolicy_modelmagic name, and thedatasets/source:block — so new usersunderstand the scaffold without leaving the file. Addresses friction #7 (no inline
documentation in generated configs).
While here, the scaffold now emits the canonical
source:dataset block instead ofthe deprecated
gitlab_identifier, so a freshly created server starts on therecommended schema (depends on #1637).
Notes
FIELD_DOCSconstant (suggested in theRFC): there is a single generation site, so a one-line-per-field constant would add
indirection without reuse. Easy to extract later if a second site appears.
Tests
test_init_resources_server_includes_domainto assert the generated config(a) contains the inline docs, (b) uses
source: {type: gitlab}rather thangitlab_identifier, and (c) validates cleanly with noDeprecationWarning.Part of the configuration-friction epic (#1205), milestone M6a. Targets
wprazuch/dataset-sourcesince it builds on thesource:schema; will retarget tothe shared base once that merges.