Skip to content

File-source docs use path: but the real config key is file: (csv/json/markdown) #312

Description

@adnaan

File-source docs use path: but the real key is file: (csv / json / markdown)

Surfaced during review of #310. The M5 PR fixed this exact class of bug for docs/sources/wasm.md (which really does use path:), and the reviewer noted csv.md has the mirror problem. It's actually all three file-source docs:

Doc Documents Source reads Result of following the docs
docs/sources/csv.md path: cfg.File (file:) — internal/source/source.go:242 csv source: file is required
docs/sources/json.md path: cfg.File (file:) — source.go:240 load failure
docs/sources/markdown.md path: cfg.File (file:) — source.go:245 load failure

(wasm correctly uses path:cfg.Path; that's the one exception, and it's already correct after #310.)

Fix

  • Change the path: examples to file: in docs/sources/{csv,json,markdown}.md, matching the working examples/lvt-source-file-test/ (json/csv) and the config.SourceConfig.File yaml:"file" field.
  • Optional: a small test asserting each docs/sources/*.md config example uses a key the corresponding source actually reads (this class of doc-vs-reality drift keeps recurring — wasm.md, now these).

Kept out of #310 to hold that PR to its M5 scope (save & share). Low-risk, docs-only.

🤖 Generated with Claude Code

https://claude.ai/code/session_018M9pJSPmG6i1D8s6rpEV4h

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions