Repository navigation
Improve Registry error messages; bump Fjell deps and publish v4.4.81
Overview
This release publishes version 4.4.81 and contains three focused changes: package version and dependency bumps, expanded and logged error output from the Registry module, and updated tests to match the expanded error text. Changes are sourced from the commit history (see referenced commits).
Improvements
- Improve Registry error reporting and add structured logging (commit 01cb7b1)
- Replace short/no-detail throws in src/Registry.ts with more detailed error messages and structured logger.error calls in these places (per commit message):
- findScopedInstance no-instance case now includes an "Available scopes" listing when no matching instance is found
- createInstance validation failure (when a factory returns an invalid value) now logs and throws a message that includes the returned type and that an instance with an operations property was expected
- register instance validation (attempting to register a non-instance) now logs and throws a more descriptive message including the provided type information
- Rationale / impact: these changes add context to Registry failures and emit structured logger.error entries to help diagnose why an instance lookup/creation/registration failed. (See commit 01cb7b1 for the exact scope of changes.)
- Replace short/no-detail throws in src/Registry.ts with more detailed error messages and structured logger.error calls in these places (per commit message):
Tests
- Update Registry tests to match expanded error output (commit 01cb7b1)
- tests/Registry.test.ts expectations were updated to assert against the expanded, multi-part error text using regular expressions (e.g., .toThrow(/...Expected instance with operations property/)) instead of asserting the previous short, exact strings.
- Rationale / impact: test assertions now tolerate the new, richer error messages introduced in the Registry changes.
Dependency and Version Changes
-
Bump package version in package.json to 4.4.81 (commit 672429e)
- The package.json version field was updated to publish this release.
-
Update Fjell package dependencies in package.json (commit 0d37db5)
- @fjell/core: ^4.4.70 → ^4.4.73
- @fjell/logging: ^4.4.62 → ^4.4.65
- devDependency @fjell/common-config: ^1.1.31 → ^1.1.36
- Rationale / impact: dependency versions were advanced; consumers using peer- or internal-version checks should note the new pinned ranges.
Breaking Changes
- Error message contents from Registry operations have changed (commit 01cb7b1)
- Any code or tests that relied on exact Registry error strings (for example, doing string equality checks on thrown messages) may need to be updated to handle the new, multi-part messages or to match via regular expressions. The test suite was already updated in this release to reflect that change.
Files changed (high level)
- package.json — version and dependency version bumps (commits 672429e, 0d37db5)
- src/Registry.ts — expanded error messages and added logger.error calls in failure paths (commit 01cb7b1)
- tests/Registry.test.ts — expectations updated to match the expanded messages (commit 01cb7b1)
References: