config dump omits per-file overlays and inherited default-component-config
Maintainers usually reply within 7 days
Assessment
This issue has not been assessed yet.
Description
Summary
azldev config dump presents itself as showing the "fully resolved project configuration", but it stops at the file-level merge and does not run the per-component resolver. As a result, two important sources of effective configuration are invisible in the dump even though builds honor them:
overlay-filesexpansion — overlays loaded fromoverlays/*.overlay.toml(per-file overlay format, docs) never appear incomponents.<name>.overlays.- Inherited
default-component-config— fields injected from project/distro/component-group defaults never appear on the concrete component.
Downstream commands (build, render, prepare-sources, diff-sources) do run the resolver (applyInheritedDefaultsToComponent → ExpandResolvedOverlayFiles), so the artifacts they produce are correct. The gap is display-only, but it makes config dump misleading as an authoring/debugging aid.
Repro
Given a component using the per-file overlay format:
# base/comps/GraphicsMagick/GraphicsMagick.comp.toml
[components.GraphicsMagick]
overlay-files = ["overlays/*.overlay.toml"]
# base/comps/GraphicsMagick/overlays/0001-drop-libheif-build-dependency.overlay.toml
[metadata]
category = "azl-dep-missing-workaround"
[[overlays]]
type = "spec-remove-tag"
tag = "BuildRequires"
value = "libheif-devel"
Then:
$ azldev config dump -f json | jq '.components.GraphicsMagick.overlays'
null
But azldev component list -p GraphicsMagick -O json | jq '.[0].Overlays' shows the overlay, and azldev component render -p GraphicsMagick correctly removes the BuildRequires: libheif-devel line from the rendered spec.
Impact
- Confuses users during authoring — a config that clearly "works" appears empty in the dump, prompting incorrect "my overlays aren't being applied" diagnoses.
- Blocks the documented pattern of using
azldev config dump -q -O json | jq ...for ad-hoc queries about effective component config (works today only for fields authored inline). - Makes the MCP
config-dumptool less useful for coding agents that ask "what is the effective config for component X?".
Suggested fix
Add a flag to config dump that runs the per-component resolver before serialization. Some options:
- A (preferred):
azldev config dump --resolved(or--expand) — off by default to preserve today's round-trippable output; when set, iterates components through the resolver and replaces thecomponentsmap with resolved copies (including expandedoverlaysand merged inherited defaults). - B: Always dump the resolved view; drop the round-trippability guarantee. Breaking change; probably not worth it.
- C: Documentation-only — clarify in
Longhelp and config-file.md thatconfig dumpis pre-resolver and point users tocomponent list -O jsonfor the resolved view. Cheapest fix but doesn't help the MCP-tool case.
Happy to send a PR for option A if the team agrees on the shape.
Related code
- Dump entry point:
internal/app/azldev/cmds/config/dump.go— marshals rawenv.Config(). - Resolver used by build/render/prepare-sources:
internal/app/azldev/core/components/resolver.go—Resolver.FindComponents→getComponentFromNameAndSpecPath→applyInheritedDefaultsToComponent→ExpandResolvedOverlayFiles. - Feature introduced by PR #256 (per-file overlays / inherited
overlay-files); this gap has existed since then.
- Dominant language
- Go
- Stars
- 18
- Forks
- 29
- Avg merge
- 6d 19h
- Merged PRs (30d)
- 19
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoft/azure-linux-dev-tools
-
`patch-add` overlay appends `PatchN:` tag at end of preamble instead of grouping with existing Patch tagsPossibly taken @IzanVil claimed this 13 days ago. Openarea: overlays enhancement priority: low
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
microsoft/azure-linux-dev-tools#284 · 2 comments ·
Maintainers usually reply within 7 days
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 15/100
microsoft/azure-linux-dev-tools#374 ·
Maintainers usually reply within 7 days
-
[Bug]: no specification for TOML object modelMay be free again @ddstreet claimed this 39 days ago, and no pull request is open. Openbug
microsoft/azure-linux-dev-tools#318 · 1 comment · 1 assignee ·
Maintainers usually reply within 7 days
-
[Bug]: azldev comp render doesn't always add changelog entriesMay be free again @ddstreet claimed this 51 days ago, and no pull request is open. Openbug GA blocker
microsoft/azure-linux-dev-tools#316 · 1 assignee ·
Maintainers usually reply within 7 days
-
[Bug]: Findings from first pass at mutation testingMay be free again @liunan-ms claimed this 39 days ago, and no pull request is open. Openarea: testing bug
microsoft/azure-linux-dev-tools#245 · 1 assignee ·
Maintainers usually reply within 7 days
All issues in microsoft/azure-linux-dev-tools
Similar issues
-
bug triage
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
FairwindsOps/nova#484 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
Maintainers usually reply within 1 day
-
automated-analysis code-quality cookie
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
github/gh-aw#67517 · 3 comments ·
Maintainers usually reply within 1 day
-
[otelcol] print-config help text still requires the removed otelcol.printInitialConfig feature gatePossibly taken @girishkvs claimed this today. Open
Difficulty 1/5 Under an hour Newbie friendliness 88/100
open-telemetry/opentelemetry-collector#16143 · 1 comment ·
Maintainers usually reply within 1 day
-
bug good first issue load-balancing
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
ktrubilo9/edge-proxy#53 ·