Skip to content

fix(environments): accept gddy's nested environments.toml shape#59

Merged
jpage-godaddy merged 1 commit into
mainfrom
env-compat
Jul 21, 2026
Merged

fix(environments): accept gddy's nested environments.toml shape#59
jpage-godaddy merged 1 commit into
mainfrom
env-compat

Conversation

@jpage-godaddy

Copy link
Copy Markdown
Collaborator

Summary

  • gddy's already-distributed environments.toml nests entries under a top-level [environments.<name>] table (mirroring gddy's own hand-rolled EnvironmentsFile { environments: BTreeMap<..> } ), but Environments::file_defs() only parsed the flat [<name>] shape.
  • Parses both shapes now: the recommended flat [<name>] shape stays the documented/canonical one; the nested [environments.<name>] shape is accepted as an undocumented compatibility shim so already-shipped files parse without edits. When a name appears in both, the nested entry's fields win.
  • Unblocks DEVEX-929 (gddy adopting cli-engine's shared Environments type instead of its own hand-rolled rust/src/environments/mod.rs).

Test plan

  • cargo fmt --all --check
  • cargo clippy --all-targets -- -D warnings
  • RUSTDOCFLAGS='-D warnings' cargo doc --no-deps
  • cargo test --all-targets (all suites pass, incl. new nested_environments_table_shape_parses_like_flat_shape and nested_environments_table_wins_over_flat_entry_for_same_name)
  • cargo test --doc
  • cargo rustdoc --lib -- -W missing-docs (zero warnings)

🤖 Generated with Claude Code

gddy's already-distributed environments.toml nests entries under a
top-level [environments.<name>] table, but Environments::file_defs()
only parsed the flat [<name>] shape, so those files would silently
fail to resolve any environment once gddy adopts this engine's
Environments type instead of its own hand-rolled resolution.

DEVEX-929

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@jpage-godaddy
jpage-godaddy merged commit e9209b4 into main Jul 21, 2026
2 checks passed
@jpage-godaddy
jpage-godaddy deleted the env-compat branch July 21, 2026 22:22
jpage-godaddy pushed a commit that referenced this pull request Jul 22, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.4.8](cli-engine-v0.4.7...cli-engine-v0.4.8)
(2026-07-21)


### Bug Fixes

* **environments:** accept gddy's nested environments.toml shape
([#59](#59))
([e9209b4](e9209b4))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants