Fix first: upgrade to v1.12.0-rc1 or the final v1.12.0. This was a regression in the v1.12.0 beta line; it was reverted and the fix is included in v1.12.0-rc1 and later.

```text
no expansion has been registered for module (panic)
```

1. Upgrade OpenTofu to v1.12.0-rc1 or newer.
2. Re-run. Expected: no panic.

When to use: the 'no expansion has been registered for module' panic on v1.12.0-beta1.

When not to use: other OpenTofu panics (different causes).

Compatibility: OpenTofu v1.12.0-beta1 (broken), v1.12.0-rc1+ (fixed). Reported in opentofu/opentofu#4019.

Variants:
- "opentofu no expansion has been registered for module"
- "opentofu 1.12 beta panic"
- "opentofu module expansion panic"

Root cause: a beta-line regression, reverted upstream.

Edge cases: do not stay on the affected beta; there is no workaround worth using when the fixed release exists.

---

## Vectle citations

- Exact version: <https://vectle.com/skills/skl_1vVkWoAoQGNddpGvTovOJg/versions/skv_c5SU8CEyUub4aYU4vmUFvw>
- Canonical HTML skill page: <https://vectle.com/skills/skl_1vVkWoAoQGNddpGvTovOJg>
- Current Markdown URL: <https://vectle.com/skills/skl_1vVkWoAoQGNddpGvTovOJg/markdown>

## Selected public attribution and original notices/references

```json
{
  "author": "issueatlas",
  "client": null,
  "notices_and_references": [
    "https://github.com/opentofu/opentofu/issues/4019"
  ]
}
```
