mjdi docsv0.10.0latest
Migration notes (0.9.0)
Every change in mjdi 0.9.0 classified per the release policy. The default
Source: mjdi/docs/migration-notes.md
Every change in mjdi 0.9.0 classified per the release policy. The default is documenting and testing existing behavior — no silent breaking changes.
Additive (new API, no existing code affected)
| Addition | Where | Notes |
|---|---|---|
debug_tracking container/scope parameter (5th, default False) | Container, Scope, create_scope, the guards and testing helpers | Existing spellings (Container[reg], Container[reg, True], Container[reg, True, True], Container[reg, True, True, False]) keep their exact meaning; the new parameter defaults to off. |
DebugLog type | mjdi.observability | Pull-model log; exported with the observability family. |
debug_report() / debug_count() / was_closed() | Container, Scope | debug_* accessors return empty/zero in the default specialization; was_closed() is informational in all specializations. |
| Destructor diagnostics MJDI-D001/D002 | debug_tracking=True specializations only | Print-only, at drop time; the default specialization never prints. |
| Factory-failure wrapper MJDI-R004 | FactoryProvider.supply_as | See "behavior clarification" below. |
| Stable diagnostic IDs in message text | every diagnostic | See "behavior clarification" below. |
scripts/validate_metadata.py, scripts/release_update_docs.py, scripts/test_inventory.py, scripts/release_gate.sh | release tooling | Not part of the runtime library. |
| New test files, fixtures, and golden checks | tests/, scripts/run_tests.sh | Purely additive; no existing test weakened or deleted. |
Behavior clarifications (messages only; failure modes unchanged)
- Diagnostic messages now end with
[diagnostic MJDI-XXX]. Tests that match message fragments (substring matches) are unaffected — the stable leadingmjdi:fragments are unchanged. Tests that matched a whole message verbatim need the suffix added (mjdi's own suite pins fragments, not whole messages). - Factory failures are wrapped (MJDI-R004). Previously the factory's
error propagated verbatim; it now propagates wrapped with the service
type, the operation, and the original text preserved as
Underlying cause: <original>. Any test matching the original fragment keeps passing; tests asserting the exact full message need updating. The error type and raisability are unchanged. MJDI-R001/MJDI-R002messages gained remediation text (thewith_scopeguard; thevalidate_runtime()startup suggestion). Same failure modes, same leading fragments, same IDs (R001/R002 were already the catalog's pinned IDs).
Bug fixes (correctness, no API change)
override_missing_target_messageembedded the wrong diagnostic ID (MJDI-E011, which belongs to the unregistered-resolve diagnostic). It now embeds its correct pinned IDMJDI-E008.- The diagnostics catalog documented a factory-failure message pattern ("mjdi: the factory function raised") that no code emitted. The P0-08 wrapper makes the catalog entry real.
missing_provider_messageinerrors.mojowas dead code (imported byregistry.mojobut never called); removed together with the unused import. The live missing-provider diagnostic isdependency_graph.mojo'sMJDI-E007builder.- The diagnostics catalog had cataloged five library diagnostics with no
IDs (circular dependency, lifetime conflict, and the three alias
validation reports). All now carry pinned IDs (
MJDI-E015–MJDI-E019,MJDI-E020).
Deprecated
Nothing. mjdi has no deprecated surface in 0.9.0.
Breaking
Nothing. The close semantics, alias semantics, and scope semantics
documented by the P0 work are the inherited behaviors, now pinned by tests
(see docs/close-semantics.md,
docs/alias-semantics.md, and
docs/scope-behavior-matrix.md). Any future
proposal to change one of those rows must be announced in this file first.