{
  "slug": "terragrunt-stack-dependencies-resolves-nested-stack-paths-7e1d90af9515",
  "title": "terragrunt stack-dependencies resolves nested stack paths",
  "tools": [
    "terragrunt"
  ],
  "tags": [
    "agent"
  ],
  "introduced_at": "2026-04-27T14:17:59.000Z",
  "announced_at": "2026-04-27T14:17:59.000Z",
  "effective_at": null,
  "date_basis": "source-publication",
  "status": "unknown",
  "how": {
    "incantation": "When a unit in a parent stack must depend on a nested stack, enable `stack-dependencies` and set the dependency’s `config_path` to `stack.<name>.<nested_stack>.path` (for example, `stack.infra.deep.path`).",
    "examples": [
      "unit \"app\" {\n  source = \"../catalog/units/app\"\n  path   = \"app\"\n\n  autoinclude {\n    dependency \"deep\" {\n      config_path = stack.infra.deep.path\n    }\n  }\n}"
    ],
    "gotchas": [
      "Version: v1.0.3",
      "Availability: The `stack-dependencies` experiment is required.",
      "stack-dependencies (required): Experiment to enable for this feature in v1.0.3.",
      "autoinclude (required): Unit block that supplies configuration merged into the generated unit configuration.",
      "dependency \"deep\" (required): Dependency block; `deep` is its label.",
      "config_path (required): Path to the dependency configuration. Here it uses the nested stack path reference.",
      "stack.infra.deep.path (required): Reference to the generated path of the `deep` stack nested under `infra`, as stated in the v1.0.3 release note.",
      "Prerequisite: Enable the `stack-dependencies` experiment.",
      "Prerequisite: Declare the nested stack in the referenced stack’s `terragrunt.stack.hcl`; the release note example names `catalog/stacks/infra/terragrunt.stack.hcl`.",
      "Docs conflict: Current HCL blocks documentation says stacks are opaque dependency boundaries and path references cannot target a component inside another stack. This differs from the v1.0.3 release note’s nested-stack behavior; the current page documents a newer behavior/version. https://docs.terragrunt.com/reference/hcl/blocks/"
    ]
  },
  "why_it_matters": "Declare a dependency in a unit of a parent stack on a stack nested inside one of its stacks.",
  "before": "Previously, `stack-dependencies` supported `stack.<name>.path` for a whole stack and `stack.<name>.<unit_name>.path` for a unit inside a stack; it did not resolve the nested-stack reference described by this change.",
  "sources": [
    "https://github.com/gruntwork-io/terragrunt/releases/tag/v1.0.3",
    "https://docs.terragrunt.com/reference/hcl/blocks/"
  ],
  "rank": 0.95018,
  "judge": {
    "publish": true,
    "judge_model": "codex-cli/gpt-6-luna+typesafe/jev-1.13.0",
    "prompt_version": "extract-v7+enrich-v2+judge-v2x3+jev-publish-v1"
  },
  "review_state": "approved",
  "provenance": {
    "run_id": "wave2a-20261017",
    "verdict_id": "wave2a-20261017:wave2a-20261017-fcea54bb20ea13c8-7:gate",
    "evidence_hash": "971f980a841953c3c89a14d88ab2e29c72ffa049e94b2f40e9a648581d136a5a"
  },
  "review": {
    "draft_hash": "00d08a6a37c76f0361b6d8c4d3c906c5fa917169949e7a971ed6f0178a77cbdf",
    "reviewer": "publication-gate",
    "reviewed_at": "2026-10-07T00:00:00.000Z",
    "decision": "wave2a-20261017:gate",
    "reason": "3 of 3 judge runs approved with p_yes >= 0.9 (mean 0.95 >= 0.9; 2 needed) and Jev gave 0.60 (>= 0.6 needed)."
  }
}
