Skip to content

fix: add GCP billing section to runbook generator (closes #242) - #246

Merged
elasticdotventures merged 1 commit into
mainfrom
fix/runbook-generator-gcp-billing
Sep 7, 2026
Merged

fix: add GCP billing section to runbook generator (closes #242)#246
elasticdotventures merged 1 commit into
mainfrom
fix/runbook-generator-gcp-billing

Conversation

@elasticdotventures

Copy link
Copy Markdown
Member

Summary

#237 added a GCP billing env-var table and first-run validation procedure to docs/agent-mcp-runbook.md manually, but didn't update the generated_agent_runbook_markdown() function in contract.rs. This caused runbook_is_generated_from_rust_source to fail on any branch that merged main after #237.

Fix

Appended the GCP billing section to the generator using push_str() after the format!() call — avoids the format-string escaping issues that made inline editing impractical. The push_str approach is cleaner for static documentation blocks.

Verification

  • cargo check -p ledgerr-mcp passes
  • regen-docs produces the GCP billing section (105 lines, up from 80)
  • Regeneration is idempotent (same hash on repeated runs)

Closes #242

The generated_agent_runbook_markdown() function in contract.rs was
missing the GCP billing env-var table and first-run validation
procedure that #237 added manually to the checked-in runbook file.

Changed format!(...) to let mut runbook = format!(...); runbook.push_str(...)
to append the section without fighting format-string escaping. The
push_str approach is cleaner for static documentation blocks.

Regenerated docs/agent-mcp-runbook.md — now105 lines with the GCP
billing section. Verified idempotent (regen-docs produces same output).

Closes #242
@elasticdotventures
elasticdotventures merged commit eabfb07 into main Sep 7, 2026
9 checks passed
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.

feat: add GCP billing env-var table to runbook generator (contract.rs)

1 participant