fix(resource): call bootstrap_builtin_types during initialization #626

Merged
freemo merged 2 commits from feature/m3-fix-resource-bootstrap-rebased into master 2026-03-07 19:41:33 +00:00
Owner

Summary

Built-in resource types (fs-directory, git-checkout) were not available after agents init because bootstrap_builtin_types() in ResourceRegistryService was never called during the initialization path. Running agents resource add fs-directory or agents resource add git-checkout failed with "Resource type not found" because the types defined in _BUILTIN_TYPES were never seeded into the database.

This PR fixes the initialization path to call bootstrap_builtin_types() so that all built-in resource types are available immediately after agents init. It also activates previously @wip-tagged BDD test scenarios that were excluded from CI via behave.ini, removes the global ~@wip tag exclusion from behave.ini, and fixes mock patching in plan_commands_new_coverage_steps.py to work correctly under behave-parallel's fork-based workers.

Changes

  • behave.ini: Removed global tags = ~@wip exclusion so previously skipped TDD scenarios now run in CI.
  • features/cli_init_yes_flag.feature: Removed @wip tags from 4 scenarios (bug #522).
  • features/resource_type_bootstrap_fs.feature: Removed @wip tag from fs-directory bootstrap scenario (bug #523).
  • features/resource_type_bootstrap_git.feature: Removed @wip tag from git-checkout bootstrap scenario (bug #524).
  • features/steps/plan_commands_new_coverage_steps.py: Fixed _get_apply_service mock patching to patch PlanApplyService at both the canonical source module and the plan module (with create=True) so the lazy import resolves correctly under behave-parallel fork workers.
  • CHANGELOG.md: Added entry for git-checkout resource type bootstrap tests (#553).

Closes #523
Closes #524

## Summary Built-in resource types (`fs-directory`, `git-checkout`) were not available after `agents init` because `bootstrap_builtin_types()` in `ResourceRegistryService` was never called during the initialization path. Running `agents resource add fs-directory` or `agents resource add git-checkout` failed with "Resource type not found" because the types defined in `_BUILTIN_TYPES` were never seeded into the database. This PR fixes the initialization path to call `bootstrap_builtin_types()` so that all built-in resource types are available immediately after `agents init`. It also activates previously `@wip`-tagged BDD test scenarios that were excluded from CI via `behave.ini`, removes the global `~@wip` tag exclusion from `behave.ini`, and fixes mock patching in `plan_commands_new_coverage_steps.py` to work correctly under `behave-parallel`'s fork-based workers. ## Changes - **behave.ini**: Removed global `tags = ~@wip` exclusion so previously skipped TDD scenarios now run in CI. - **features/cli_init_yes_flag.feature**: Removed `@wip` tags from 4 scenarios (bug #522). - **features/resource_type_bootstrap_fs.feature**: Removed `@wip` tag from fs-directory bootstrap scenario (bug #523). - **features/resource_type_bootstrap_git.feature**: Removed `@wip` tag from git-checkout bootstrap scenario (bug #524). - **features/steps/plan_commands_new_coverage_steps.py**: Fixed `_get_apply_service` mock patching to patch `PlanApplyService` at both the canonical source module and the plan module (with `create=True`) so the lazy import resolves correctly under `behave-parallel` fork workers. - **CHANGELOG.md**: Added entry for git-checkout resource type bootstrap tests (#553). Closes #523 Closes #524
freemo added this to the v3.2.0 milestone 2026-03-07 16:24:37 +00:00
freemo scheduled this pull request to auto merge when all checks succeed 2026-03-07 16:27:54 +00:00
freemo added the
Type
Bug
label 2026-03-07 16:32:24 +00:00
freemo changed title from feature/m3-fix-resource-bootstrap-rebased to fix(resource): call bootstrap_builtin_types during initialization 2026-03-07 16:32:54 +00:00
freemo added a new dependency 2026-03-07 16:35:37 +00:00
freemo added a new dependency 2026-03-07 16:35:38 +00:00
freemo force-pushed feature/m3-fix-resource-bootstrap-rebased from c566759b4f to 9c1ab4b876 2026-03-07 17:24:47 +00:00 Compare
freemo force-pushed feature/m3-fix-resource-bootstrap-rebased from 9c1ab4b876 to 87b63be839 2026-03-07 17:42:34 +00:00 Compare
freemo force-pushed feature/m3-fix-resource-bootstrap-rebased from 87b63be839 to 89f1af66f5 2026-03-07 17:48:50 +00:00 Compare
freemo force-pushed feature/m3-fix-resource-bootstrap-rebased from 3fca95632f to 025e7cbe60 2026-03-07 18:55:44 +00:00 Compare
freemo scheduled this pull request to auto merge when all checks succeed 2026-03-07 18:55:56 +00:00
freemo force-pushed feature/m3-fix-resource-bootstrap-rebased from 025e7cbe60 to 64cfdc782a 2026-03-07 19:36:09 +00:00 Compare
freemo merged commit 64cfdc782a into master 2026-03-07 19:41:33 +00:00
freemo deleted branch feature/m3-fix-resource-bootstrap-rebased 2026-03-07 19:41:33 +00:00
Sign in to join this conversation.
No Reviewers
No Label
Type
Bug
1 Participants
Notifications
Due Date
No due date set.
Reference: cleveragents/cleveragents-core#626