agentbundle 0.29.0__tar.gz → 0.29.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {agentbundle-0.29.0 → agentbundle-0.29.2}/PKG-INFO +21 -4
- {agentbundle-0.29.0 → agentbundle-0.29.2}/README-pypi.md +20 -3
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/adapter_root_bins.py +6 -7
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/self_host.py +74 -29
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/self_host.py +10 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/version.py +1 -1
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/workspace_mcp.py +105 -24
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle.egg-info/PKG-INFO +21 -4
- {agentbundle-0.29.0 → agentbundle-0.29.2}/pyproject.toml +1 -1
- {agentbundle-0.29.0 → agentbundle-0.29.2}/tests/test_workspace_mcp_git.py +5 -16
- {agentbundle-0.29.0 → agentbundle-0.29.2}/README.md +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/__init__.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/__main__.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/adapter.schema.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/adapter.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/guides/_shared/reference/catalogue-authoring-standards.md +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/guides/_shared/reference/catalogue-ci-contract.md +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/manifest.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/packs/AGENTS.md +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/packs/README.md +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/packs/_example/README.md +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/packs/_example/evals/eval_queries.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/packs/_example/pack.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/profiles/AGENTS.md +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/profiles/README.md +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/profiles/_example/README.md +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue-scaffold/profiles/_example/profile.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/catalogue.schema.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/guide.schema.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/install-defaults.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/install-marker.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/pack.schema.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/plugin-manifest.derived.schema.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/plugin-manifest.schema.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/profile.schema.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/skill-manifest.schema.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/skill.schema.json +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/_data/target-vocab.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/__init__.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/__main__.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/adapters/__init__.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/adapters/claude_code.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/adapters/codex.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/adapters/copilot.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/adapters/cursor.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/adapters/gemini.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/adapters/kiro.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/adapters/kiro_cli.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/adapters/kiro_ide.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/contract.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/lint_packs.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/main.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/phase_order.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/__init__.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/codex_agent_toml.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/copilot_agent_md.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/copilot_hooks_json.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/direct_directory.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/gemini_command_toml.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/hook_id.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/kiro_ide_hook.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/merge_into_agent_json.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/merge_json.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/projections/user_merge_json.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/recipes/composite-agents-md.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/recipes/composite-marketplace.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/recipes/marketplace.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/recipes/per-pack-apm-package.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/recipes/per-pack-claude-plugin.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/recipes/per-pack-overlay.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/recipes/self-host.toml +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/scope_rails.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/shared_libs.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/target_resolver.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/__init__.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_adapter_claude_code.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_adapter_codex.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_adapter_copilot.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_adapter_cursor.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_adapter_gemini.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_adapter_kiro.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_adapter_kiro_alias.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_adapter_kiro_cli.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_adapter_kiro_ide.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_adapter_root_bins_projection.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_architect_design_reviewer_projection.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_architect_design_reviewer_rubric_parity.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_build_ships_seeds.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_contract.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_contract_scope.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_contract_v07.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_contract_v08.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_direct_directory_cleanup.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_end_to_end_build.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_lint_agents_md_diataxis_block.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_lint_agents_md_legacy_block.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_lint_agents_md_risk_block.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_lint_packs.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_load_pack_hook_wiring_safely.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_pack_schema.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_pack_schema_allowed_adapters.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_pack_schema_install.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_pipeline.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_plugin_manifest_schema.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_projectable_subset.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_projections_merge_json.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_scope_rails.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_security.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_self_host_check.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_self_host_fixture_guard.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_self_host_recipe_config.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_shared_libs_projection.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_shared_prefix_contract.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_shipped_packs_v07_declarations.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_shipped_packs_v08_declarations.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_user_libs_projection.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_validate.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_workspace_status_projection.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/tests/test_writers_emit_lf.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/user_libs.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/build/validate.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/__init__.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/archive.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/build.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/config.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/defaults.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/diagnostics.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/identity.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/initialise.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/initialise_self_hosted.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/lint.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/package.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/results.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/self_host_windows.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/skill_spec_lint.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/toml_emit.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/catalogue_tooling/verify.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/categories.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/cli.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/__init__.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/_common.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/_drop_warning.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/adapt.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/catalogue_build.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/catalogue_init.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/catalogue_lint.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/catalogue_package.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/catalogue_self_host.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/catalogue_sync_defaults.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/catalogue_tooling_stub.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/catalogue_verify.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/config.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/diff.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/docs.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/init_state.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/install.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/list_installed.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/list_packs.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/list_profiles.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/list_targets.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/oplog_cmd.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/pack_config_cmd.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/pack_evals.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/package_catalogue.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/profile.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/reconcile.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/render.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/scaffold.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/show.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/uninstall.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/upgrade.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/commands/validate.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/config.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/https_catalogue.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/local_exclude.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/oplog.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/pack_inventory.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/render.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/safety.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/scaffold.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/scope.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/source_defaults.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/statelock.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle/user_config.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle.egg-info/SOURCES.txt +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle.egg-info/dependency_links.txt +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle.egg-info/entry_points.txt +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle.egg-info/requires.txt +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/agentbundle.egg-info/top_level.txt +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/setup.cfg +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/tests/test_adapter_permissions_projection.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/tests/test_linear_primitive.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/tests/test_loop_engine_events_jsonl.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/tests/test_workspace_mcp_elicit.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/tests/test_workspace_mcp_event_bridge.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/tests/test_workspace_mcp_lifecycle.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/tests/test_workspace_mcp_stdin.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/tests/test_workspace_mcp_tools.py +0 -0
- {agentbundle-0.29.0 → agentbundle-0.29.2}/tests/test_workspace_status_engine_autonomous.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: agentbundle
|
|
3
|
-
Version: 0.29.
|
|
3
|
+
Version: 0.29.2
|
|
4
4
|
Summary: npm for your coding agent. Install packs of skills, subagents, and hooks into any repo, for every major agent.
|
|
5
5
|
Author-email: eugenelim <eugenelim@users.noreply.github.com>
|
|
6
6
|
License: Apache-2.0 OR MIT
|
|
@@ -289,6 +289,15 @@ agentbundle catalogue self-host --check --root .
|
|
|
289
289
|
|
|
290
290
|
Exits non-zero if any projected file is out of date. Safe to run in CI as a required check; use `--write` locally to regenerate.
|
|
291
291
|
|
|
292
|
+
By default projects for `claude-code` and `codex`. Downstream repos that use a single adapter (e.g. `kiro-ide`) can declare it in `catalogue.toml` — only that adapter is then projected, and its output files participate in the drift check:
|
|
293
|
+
|
|
294
|
+
```toml
|
|
295
|
+
[distribution.agentbundle]
|
|
296
|
+
preferred-adapter = "kiro-ide"
|
|
297
|
+
```
|
|
298
|
+
|
|
299
|
+
When `preferred-adapter` names an adapter not in the upstream `SELF_HOST_ADAPTERS` list, the self-host engine switches to single-adapter mode: only the named adapter is projected; Claude Code-specific artifacts (`.claude/`, `.codex/`, `.claude-plugin/`, `CLAUDE.md`) are neither written nor drift-checked.
|
|
300
|
+
|
|
292
301
|
**Run Tier-A activation evals** to measure whether each covered skill fires on the prompts it should:
|
|
293
302
|
|
|
294
303
|
```bash
|
|
@@ -349,15 +358,23 @@ each Claude Code session. It exposes six tools over MCP stdio:
|
|
|
349
358
|
python3 -m agentbundle.workspace_mcp
|
|
350
359
|
```
|
|
351
360
|
|
|
361
|
+
> **Trusted checkout only.** This form runs whichever `agentbundle` is on
|
|
362
|
+
> `sys.path`. If the repo uses an editable install (`pip install -e .`), it
|
|
363
|
+
> runs the local checkout's code. Use only on repos you trust. An isolated
|
|
364
|
+
> spawn mode (`python3 -I -m agentbundle.workspace_mcp`) is planned for
|
|
365
|
+
> Stage 2 and will require a stable non-editable install.
|
|
366
|
+
|
|
352
367
|
**Inject the session instruction** so the agent knows to use the tools:
|
|
353
368
|
|
|
354
369
|
```python
|
|
355
370
|
from agentbundle.workspace_mcp import DEFAULT_SESSION_INSTRUCTION
|
|
356
371
|
```
|
|
357
372
|
|
|
358
|
-
Pass
|
|
359
|
-
`
|
|
360
|
-
|
|
373
|
+
Pass exactly one environment variable when spawning to set the session mode:
|
|
374
|
+
`WORKSPACE_MCP_SPEC_PATH` (path to the spec directory) for FSM/work-loop items,
|
|
375
|
+
or `WORKSPACE_MCP_DISPATCHED_ITEM` (`ini_slug/type:slug`) for non-FSM shaping
|
|
376
|
+
items. Setting neither gives discovery-only mode (git writes disabled). Setting
|
|
377
|
+
both is unsupported — only one selects the mode.
|
|
361
378
|
|
|
362
379
|
## Credentials
|
|
363
380
|
|
|
@@ -267,6 +267,15 @@ agentbundle catalogue self-host --check --root .
|
|
|
267
267
|
|
|
268
268
|
Exits non-zero if any projected file is out of date. Safe to run in CI as a required check; use `--write` locally to regenerate.
|
|
269
269
|
|
|
270
|
+
By default projects for `claude-code` and `codex`. Downstream repos that use a single adapter (e.g. `kiro-ide`) can declare it in `catalogue.toml` — only that adapter is then projected, and its output files participate in the drift check:
|
|
271
|
+
|
|
272
|
+
```toml
|
|
273
|
+
[distribution.agentbundle]
|
|
274
|
+
preferred-adapter = "kiro-ide"
|
|
275
|
+
```
|
|
276
|
+
|
|
277
|
+
When `preferred-adapter` names an adapter not in the upstream `SELF_HOST_ADAPTERS` list, the self-host engine switches to single-adapter mode: only the named adapter is projected; Claude Code-specific artifacts (`.claude/`, `.codex/`, `.claude-plugin/`, `CLAUDE.md`) are neither written nor drift-checked.
|
|
278
|
+
|
|
270
279
|
**Run Tier-A activation evals** to measure whether each covered skill fires on the prompts it should:
|
|
271
280
|
|
|
272
281
|
```bash
|
|
@@ -327,15 +336,23 @@ each Claude Code session. It exposes six tools over MCP stdio:
|
|
|
327
336
|
python3 -m agentbundle.workspace_mcp
|
|
328
337
|
```
|
|
329
338
|
|
|
339
|
+
> **Trusted checkout only.** This form runs whichever `agentbundle` is on
|
|
340
|
+
> `sys.path`. If the repo uses an editable install (`pip install -e .`), it
|
|
341
|
+
> runs the local checkout's code. Use only on repos you trust. An isolated
|
|
342
|
+
> spawn mode (`python3 -I -m agentbundle.workspace_mcp`) is planned for
|
|
343
|
+
> Stage 2 and will require a stable non-editable install.
|
|
344
|
+
|
|
330
345
|
**Inject the session instruction** so the agent knows to use the tools:
|
|
331
346
|
|
|
332
347
|
```python
|
|
333
348
|
from agentbundle.workspace_mcp import DEFAULT_SESSION_INSTRUCTION
|
|
334
349
|
```
|
|
335
350
|
|
|
336
|
-
Pass
|
|
337
|
-
`
|
|
338
|
-
|
|
351
|
+
Pass exactly one environment variable when spawning to set the session mode:
|
|
352
|
+
`WORKSPACE_MCP_SPEC_PATH` (path to the spec directory) for FSM/work-loop items,
|
|
353
|
+
or `WORKSPACE_MCP_DISPATCHED_ITEM` (`ini_slug/type:slug`) for non-FSM shaping
|
|
354
|
+
items. Setting neither gives discovery-only mode (git writes disabled). Setting
|
|
355
|
+
both is unsupported — only one selects the mode.
|
|
339
356
|
|
|
340
357
|
## Credentials
|
|
341
358
|
|
|
@@ -34,9 +34,9 @@ shell-config edits.
|
|
|
34
34
|
|
|
35
35
|
from __future__ import annotations
|
|
36
36
|
|
|
37
|
+
import contextlib
|
|
37
38
|
import os
|
|
38
39
|
import shutil
|
|
39
|
-
import stat
|
|
40
40
|
from dataclasses import dataclass
|
|
41
41
|
from pathlib import Path
|
|
42
42
|
|
|
@@ -309,19 +309,18 @@ def apply_projection(working_tree: Path, packs_dir: Path) -> None:
|
|
|
309
309
|
expected_targets = {p.target for p in projections}
|
|
310
310
|
for proj in projections:
|
|
311
311
|
proj.target.parent.mkdir(parents=True, exist_ok=True)
|
|
312
|
-
shutil.
|
|
312
|
+
shutil.copyfile(proj.source, proj.target)
|
|
313
313
|
if os.name == "posix":
|
|
314
|
-
|
|
314
|
+
with contextlib.suppress(OSError):
|
|
315
|
+
proj.target.chmod(EXECUTABLE_MODE)
|
|
315
316
|
# Orphan removal: any *.py file under <working_tree>/.agentbundle/bin/
|
|
316
317
|
# not claimed by an expected target.
|
|
317
318
|
target_dir = working_tree / TARGET_SUBDIR
|
|
318
319
|
if target_dir.is_dir():
|
|
319
320
|
for existing in sorted(target_dir.glob("*.py")):
|
|
320
321
|
if existing not in expected_targets:
|
|
321
|
-
|
|
322
|
+
with contextlib.suppress(FileNotFoundError): # pragma: no cover — race-only
|
|
322
323
|
existing.unlink()
|
|
323
|
-
except FileNotFoundError: # pragma: no cover — race-only
|
|
324
|
-
pass
|
|
325
324
|
|
|
326
325
|
|
|
327
326
|
def check_drift(working_tree: Path, packs_dir: Path) -> list[str]:
|
|
@@ -336,7 +335,7 @@ def check_drift(working_tree: Path, packs_dir: Path) -> list[str]:
|
|
|
336
335
|
"""
|
|
337
336
|
drifts: list[str] = []
|
|
338
337
|
try:
|
|
339
|
-
|
|
338
|
+
collect_sources(packs_dir)
|
|
340
339
|
except ValueError as exc:
|
|
341
340
|
drifts.append(f"[adapter-root-bins] {exc}; run: make build-self")
|
|
342
341
|
return drifts
|
|
@@ -23,10 +23,12 @@ consumer.
|
|
|
23
23
|
|
|
24
24
|
Self-host scope (see docs/specs/self-hosting/spec.md § Phased rollout):
|
|
25
25
|
the `SELF_HOST_ADAPTERS` allow-list runs `claude-code` and `codex`.
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
`
|
|
26
|
+
Both `SELF_HOST_ADAPTERS` and `SELF_HOST_PACKS` are sourced from
|
|
27
|
+
`recipes/self-host.toml` (see the `_DEFAULT_*` block below); the values
|
|
28
|
+
named here are the current defaults. When `catalogue.toml` declares a
|
|
29
|
+
`preferred-adapter` outside `SELF_HOST_ADAPTERS` (e.g. ``"kiro-ide"``),
|
|
30
|
+
`run_self_host` restricts projection to that adapter only — see
|
|
31
|
+
`_effective_adapters`.
|
|
30
32
|
"""
|
|
31
33
|
|
|
32
34
|
from __future__ import annotations
|
|
@@ -76,6 +78,7 @@ TARGET_PATHS = (
|
|
|
76
78
|
Path(".claude"),
|
|
77
79
|
Path(".codex"),
|
|
78
80
|
Path(".agents"),
|
|
81
|
+
Path(".kiro"),
|
|
79
82
|
Path("tools") / "hooks",
|
|
80
83
|
Path(".github") / "instructions",
|
|
81
84
|
Path("AGENTS.md"),
|
|
@@ -84,12 +87,12 @@ TARGET_PATHS = (
|
|
|
84
87
|
# Built-in fallbacks for the self-host pack / adapter allow-lists. The
|
|
85
88
|
# authoritative values live in `recipes/self-host.toml` (read at import below);
|
|
86
89
|
# these are used only when that recipe is missing a key or can't be read, so
|
|
87
|
-
# module import stays total.
|
|
88
|
-
#
|
|
89
|
-
#
|
|
90
|
-
#
|
|
91
|
-
#
|
|
92
|
-
#
|
|
90
|
+
# module import stays total. This repo is the catalogue's home, not an adopter,
|
|
91
|
+
# so `make build-self` only projects the in-house packs;
|
|
92
|
+
# `_aggregate_marketplace` intentionally ignores the pack filter — the
|
|
93
|
+
# catalogue advertises every pack. See the recipe for the full rationale.
|
|
94
|
+
# Adapters outside this list (e.g. `kiro-ide`) are handled via the
|
|
95
|
+
# `preferred_adapter` override path in `_effective_adapters`.
|
|
93
96
|
_DEFAULT_SELF_HOST_ADAPTERS: tuple[str, ...] = ("claude-code", "codex")
|
|
94
97
|
_DEFAULT_SELF_HOST_PACKS: tuple[str, ...] = (
|
|
95
98
|
"core",
|
|
@@ -269,29 +272,52 @@ def _clone_target_subtree(working_tree: Path, destination: Path) -> None:
|
|
|
269
272
|
target = destination / relative
|
|
270
273
|
target.parent.mkdir(parents=True, exist_ok=True)
|
|
271
274
|
if source.is_dir():
|
|
272
|
-
shutil.copytree(source, target)
|
|
275
|
+
shutil.copytree(source, target, copy_function=shutil.copy)
|
|
273
276
|
else:
|
|
274
|
-
shutil.
|
|
277
|
+
shutil.copy(source, target)
|
|
278
|
+
|
|
279
|
+
|
|
280
|
+
def _effective_adapters(preferred_adapter: str | None) -> tuple[str, ...]:
|
|
281
|
+
"""Return the adapter set to project.
|
|
282
|
+
|
|
283
|
+
When `preferred_adapter` names an adapter that is NOT already in
|
|
284
|
+
`SELF_HOST_ADAPTERS` (e.g. ``"kiro-ide"`` on a downstream repo),
|
|
285
|
+
restrict the set to that single adapter so only its output lands in
|
|
286
|
+
the shadow / working tree. Otherwise — including when
|
|
287
|
+
`preferred_adapter` is ``None`` or is already covered by
|
|
288
|
+
`SELF_HOST_ADAPTERS` — use the full allow-list unchanged, preserving
|
|
289
|
+
existing behaviour for repos like this one that project both
|
|
290
|
+
``claude-code`` and ``codex``.
|
|
291
|
+
"""
|
|
292
|
+
if preferred_adapter and preferred_adapter not in SELF_HOST_ADAPTERS:
|
|
293
|
+
return (preferred_adapter,)
|
|
294
|
+
return SELF_HOST_ADAPTERS
|
|
275
295
|
|
|
276
296
|
|
|
277
297
|
def _project_all_adapters(
|
|
278
298
|
output_root: Path,
|
|
279
299
|
packs_dir: Path,
|
|
280
300
|
contract: dict,
|
|
301
|
+
preferred_adapter: str | None = None,
|
|
281
302
|
) -> None:
|
|
282
303
|
"""Run direct self-host adapter projections against the
|
|
283
304
|
`SELF_HOST_PACKS`-filtered pack list. Pack uniqueness validation
|
|
284
305
|
still runs across every discovered pack so naming collisions in
|
|
285
306
|
user-scope-default packs aren't masked by the filter.
|
|
307
|
+
|
|
308
|
+
When `preferred_adapter` names an adapter outside `SELF_HOST_ADAPTERS`
|
|
309
|
+
(e.g. ``"kiro-ide"``), only that adapter is projected; see
|
|
310
|
+
`_effective_adapters` for the full selection logic.
|
|
286
311
|
"""
|
|
287
312
|
packs = discover_packs(packs_dir)
|
|
288
313
|
for pack in packs:
|
|
289
314
|
validate_pack_uniqueness(pack)
|
|
290
315
|
pack_paths = _filter_self_host_packs([pack.path for pack in packs])
|
|
316
|
+
effective = _effective_adapters(preferred_adapter)
|
|
291
317
|
for adapter_name in ADAPTERS:
|
|
292
318
|
if adapter_name not in contract["adapter"]:
|
|
293
319
|
continue
|
|
294
|
-
if adapter_name not in
|
|
320
|
+
if adapter_name not in effective:
|
|
295
321
|
continue
|
|
296
322
|
adapter_module = registry[adapter_name.replace("-", "_")]
|
|
297
323
|
adapter_module.project_packs(pack_paths, contract, output_root)
|
|
@@ -392,7 +418,6 @@ EXCLUDED_PATTERNS: tuple[str, ...] = (
|
|
|
392
418
|
".github/**",
|
|
393
419
|
"AGENTS.local.md",
|
|
394
420
|
"AGENTS.md", # root-level; nested AGENTS.md not excluded
|
|
395
|
-
".kiro/**",
|
|
396
421
|
"packages/agentbundle/**",
|
|
397
422
|
"packs/**",
|
|
398
423
|
"tools/**",
|
|
@@ -567,7 +592,11 @@ def _project_seeds(packs_dir: Path, output_root: Path) -> dict[Path, Path]:
|
|
|
567
592
|
continue
|
|
568
593
|
target = output_root / relative
|
|
569
594
|
target.parent.mkdir(parents=True, exist_ok=True)
|
|
570
|
-
shutil.
|
|
595
|
+
# Use shutil.copy (content + mode, no timestamps) so the shadow seed
|
|
596
|
+
# file has the same permission bits as the source regardless of umask.
|
|
597
|
+
# copyfile (content-only) would leave umask-derived mode on new files,
|
|
598
|
+
# causing false mode drift when the diff gate compares shadow vs disk.
|
|
599
|
+
shutil.copy(src, target)
|
|
571
600
|
return seen
|
|
572
601
|
|
|
573
602
|
|
|
@@ -693,6 +722,7 @@ def _recreate_claude_symlink(output_root: Path, *, force_copy: bool = False) ->
|
|
|
693
722
|
def _build_projected_to_source_map(
|
|
694
723
|
packs_dir: Path,
|
|
695
724
|
contract: dict,
|
|
725
|
+
preferred_adapter: str | None = None,
|
|
696
726
|
) -> dict[Path, Path]:
|
|
697
727
|
"""Build `{projected_relative_path → source_path}` for Phase-1
|
|
698
728
|
self-host output. Used by `diff_against_working_tree` to name the
|
|
@@ -701,12 +731,13 @@ def _build_projected_to_source_map(
|
|
|
701
731
|
if "primitive" not in contract or "adapter" not in contract:
|
|
702
732
|
return mapping
|
|
703
733
|
allow = set(SELF_HOST_PACKS)
|
|
734
|
+
effective = _effective_adapters(preferred_adapter)
|
|
704
735
|
for pack_path in sorted(packs_dir.iterdir()):
|
|
705
736
|
if not pack_path.is_dir() or not (pack_path / "pack.toml").exists():
|
|
706
737
|
continue
|
|
707
738
|
if pack_path.name not in allow:
|
|
708
739
|
continue
|
|
709
|
-
for adapter_name in
|
|
740
|
+
for adapter_name in effective:
|
|
710
741
|
if adapter_name not in contract["adapter"]:
|
|
711
742
|
continue
|
|
712
743
|
for rule in contract["adapter"][adapter_name].get("projection", []):
|
|
@@ -1060,6 +1091,7 @@ def run_self_host(
|
|
|
1060
1091
|
force: bool,
|
|
1061
1092
|
contract: dict | None = None,
|
|
1062
1093
|
no_symlink: bool = False,
|
|
1094
|
+
preferred_adapter: str | None = None,
|
|
1063
1095
|
) -> int:
|
|
1064
1096
|
"""Execute `make build-self` (or `make build-self DRY_RUN=1`).
|
|
1065
1097
|
|
|
@@ -1068,6 +1100,10 @@ def run_self_host(
|
|
|
1068
1100
|
projection → marketplace aggregation → CLAUDE.md symlink → marker
|
|
1069
1101
|
resolution. Under `dry_run`, all writes happen in a shadow temp
|
|
1070
1102
|
dir and the result is diffed against the working tree.
|
|
1103
|
+
|
|
1104
|
+
When `preferred_adapter` names an adapter not in `SELF_HOST_ADAPTERS`
|
|
1105
|
+
(e.g. ``"kiro-ide"``), only that adapter is projected and compared.
|
|
1106
|
+
Pass ``None`` (default) to use the full `SELF_HOST_ADAPTERS` list.
|
|
1071
1107
|
"""
|
|
1072
1108
|
if contract is None:
|
|
1073
1109
|
contract = load_contract(CONTRACT_PATH)
|
|
@@ -1107,11 +1143,18 @@ def run_self_host(
|
|
|
1107
1143
|
owner = discovery_flat.get("owner", "eugenelim")
|
|
1108
1144
|
marketplace_name = discovery_flat.get("project-name", "agent-ready-repo")
|
|
1109
1145
|
|
|
1146
|
+
# Gate Claude Code-specific artifacts (CLAUDE.md, .claude-plugin/) on
|
|
1147
|
+
# whether the effective adapter set includes claude-code. When
|
|
1148
|
+
# preferred-adapter is kiro-ide or kiro-cli (or any other adapter not in
|
|
1149
|
+
# SELF_HOST_ADAPTERS), those artifacts are neither written nor expected in
|
|
1150
|
+
# the drift check.
|
|
1151
|
+
_project_claude_artifacts = "claude-code" in _effective_adapters(preferred_adapter)
|
|
1152
|
+
|
|
1110
1153
|
if dry_run:
|
|
1111
1154
|
with tempfile.TemporaryDirectory(prefix="agentbundle-shadow-") as shadow_str:
|
|
1112
1155
|
shadow = Path(shadow_str)
|
|
1113
1156
|
_clone_target_subtree(working_tree, shadow)
|
|
1114
|
-
_project_all_adapters(shadow, packs_dir, contract)
|
|
1157
|
+
_project_all_adapters(shadow, packs_dir, contract, preferred_adapter)
|
|
1115
1158
|
# Compose AGENTS.md BEFORE seed projection: on a fresh tree the
|
|
1116
1159
|
# composed output (body + footer) must win over the body-only
|
|
1117
1160
|
# seed at `packs/core/seeds/AGENTS.md`; on an existing tree
|
|
@@ -1123,15 +1166,16 @@ def run_self_host(
|
|
|
1123
1166
|
except ValueError as exc:
|
|
1124
1167
|
print(f"self-host: {exc}", file=sys.stderr)
|
|
1125
1168
|
return 4
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1169
|
+
if _project_claude_artifacts:
|
|
1170
|
+
_aggregate_marketplace(packs_dir, shadow, owner=owner, name=marketplace_name)
|
|
1171
|
+
_recreate_claude_symlink(shadow, force_copy=no_symlink)
|
|
1172
|
+
extra_marker_paths = list(seed_map.keys())
|
|
1173
|
+
if _project_claude_artifacts:
|
|
1174
|
+
extra_marker_paths.append(Path(".claude-plugin") / "marketplace.json")
|
|
1131
1175
|
if agents_path is not None:
|
|
1132
1176
|
extra_marker_paths.append(Path("AGENTS.md"))
|
|
1133
1177
|
resolve_markers(shadow, discovery_flat, extra_paths=extra_marker_paths)
|
|
1134
|
-
source_map = _build_projected_to_source_map(packs_dir, contract)
|
|
1178
|
+
source_map = _build_projected_to_source_map(packs_dir, contract, preferred_adapter)
|
|
1135
1179
|
projected_paths = {
|
|
1136
1180
|
rendered.relative_to(shadow)
|
|
1137
1181
|
for rendered in shadow.rglob("*")
|
|
@@ -1169,7 +1213,7 @@ def run_self_host(
|
|
|
1169
1213
|
# and the catalogue-visible pack copy (`.apm/user-libs/credbroker/`). No-op
|
|
1170
1214
|
# outside the monorepo (package source absent — see user_libs docstring).
|
|
1171
1215
|
_user_libs_apply(working_tree, packs_dir)
|
|
1172
|
-
_project_all_adapters(working_tree, packs_dir, contract)
|
|
1216
|
+
_project_all_adapters(working_tree, packs_dir, contract, preferred_adapter)
|
|
1173
1217
|
# Compose AGENTS.md BEFORE seed projection — see dry-run branch for
|
|
1174
1218
|
# rationale (the body-only seed at packs/core/seeds/AGENTS.md must
|
|
1175
1219
|
# not race the body+footer composition on fresh trees).
|
|
@@ -1179,11 +1223,12 @@ def run_self_host(
|
|
|
1179
1223
|
except ValueError as exc:
|
|
1180
1224
|
print(f"self-host: {exc}", file=sys.stderr)
|
|
1181
1225
|
return 4
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1226
|
+
if _project_claude_artifacts:
|
|
1227
|
+
_aggregate_marketplace(packs_dir, working_tree, owner=owner, name=marketplace_name)
|
|
1228
|
+
_recreate_claude_symlink(working_tree, force_copy=no_symlink)
|
|
1229
|
+
extra_marker_paths = list(seed_map.keys())
|
|
1230
|
+
if _project_claude_artifacts:
|
|
1231
|
+
extra_marker_paths.append(Path(".claude-plugin") / "marketplace.json")
|
|
1187
1232
|
if agents_path is not None:
|
|
1188
1233
|
extra_marker_paths.append(Path("AGENTS.md"))
|
|
1189
1234
|
resolve_markers(working_tree, discovery_flat, extra_paths=extra_marker_paths)
|
|
@@ -40,6 +40,14 @@ def _make_result(ok: bool, operation: str, config: object | None) -> SelfHostRes
|
|
|
40
40
|
)
|
|
41
41
|
|
|
42
42
|
|
|
43
|
+
def _preferred_adapter(config: object | None) -> str | None:
|
|
44
|
+
"""Extract preferred_adapter from a loaded CatalogueConfig, or None."""
|
|
45
|
+
try:
|
|
46
|
+
return config.distribution.agentbundle.preferred_adapter or None # type: ignore[union-attr]
|
|
47
|
+
except AttributeError:
|
|
48
|
+
return None
|
|
49
|
+
|
|
50
|
+
|
|
43
51
|
def check_self_host(root: Path) -> SelfHostResult:
|
|
44
52
|
"""Dry-run self-host check (read-only). Returns SelfHostResult with ok=True on clean."""
|
|
45
53
|
from agentbundle.build.self_host import run_self_host
|
|
@@ -52,6 +60,7 @@ def check_self_host(root: Path) -> SelfHostResult:
|
|
|
52
60
|
packs_dir=packs_dir,
|
|
53
61
|
dry_run=True,
|
|
54
62
|
force=False,
|
|
63
|
+
preferred_adapter=_preferred_adapter(config),
|
|
55
64
|
)
|
|
56
65
|
return _make_result(ok=(rc == 0), operation="check", config=config)
|
|
57
66
|
|
|
@@ -68,5 +77,6 @@ def write_self_host(root: Path, force: bool = False) -> SelfHostResult:
|
|
|
68
77
|
packs_dir=packs_dir,
|
|
69
78
|
dry_run=False,
|
|
70
79
|
force=force,
|
|
80
|
+
preferred_adapter=_preferred_adapter(config),
|
|
71
81
|
)
|
|
72
82
|
return _make_result(ok=(rc == 0), operation="write", config=config)
|
|
@@ -966,9 +966,20 @@ class _GitTools:
|
|
|
966
966
|
def __init__(self, repo_root: Path) -> None:
|
|
967
967
|
self._repo_root = repo_root
|
|
968
968
|
spec_path = os.environ.get("WORKSPACE_MCP_SPEC_PATH")
|
|
969
|
+
# Capture raw env presence BEFORE validation: FSM mode is determined by
|
|
970
|
+
# whether the operator SUPPLIED WORKSPACE_MCP_SPEC_PATH, not whether it
|
|
971
|
+
# passes path validation. An empty string or invalid path still activates
|
|
972
|
+
# the FSM guard (fail-closed); git writes are blocked even if anchoring fails.
|
|
973
|
+
# Use `in os.environ` (not bool()) to treat "" as supplied.
|
|
974
|
+
_spec_path_supplied = "WORKSPACE_MCP_SPEC_PATH" in os.environ
|
|
969
975
|
dispatched = os.environ.get("WORKSPACE_MCP_DISPATCHED_ITEM")
|
|
976
|
+
# Capture raw dispatched presence for the both-vars warning: if the
|
|
977
|
+
# DISPATCHED_ITEM value is malformed, validation below sets dispatched=None,
|
|
978
|
+
# but the warning should still fire to signal the unsupported configuration.
|
|
979
|
+
_dispatched_supplied = "WORKSPACE_MCP_DISPATCHED_ITEM" in os.environ
|
|
970
980
|
# Validate spec_path: must resolve inside repo_root. An out-of-repo or malformed
|
|
971
|
-
# path is treated as absent
|
|
981
|
+
# path is treated as absent for event-bridge anchoring only — FSM mode
|
|
982
|
+
# is already locked by _spec_path_supplied above.
|
|
972
983
|
if spec_path:
|
|
973
984
|
try:
|
|
974
985
|
if not Path(spec_path).resolve().is_relative_to(repo_root.resolve()):
|
|
@@ -991,7 +1002,21 @@ class _GitTools:
|
|
|
991
1002
|
dispatched,
|
|
992
1003
|
)
|
|
993
1004
|
dispatched = None
|
|
994
|
-
|
|
1005
|
+
# Discovery mode: only when NEITHER env var was supplied. Use the raw
|
|
1006
|
+
# presence flag (_spec_path_supplied) so that SPEC_PATH="" stays out of
|
|
1007
|
+
# discovery mode (it is FSM mode, fail-closed).
|
|
1008
|
+
self._discovery_mode = not _spec_path_supplied and not dispatched
|
|
1009
|
+
# FSM mode: WORKSPACE_MCP_SPEC_PATH was supplied → FSM mode, regardless of
|
|
1010
|
+
# whether it passed validation (fail-closed: invalid path still blocks git
|
|
1011
|
+
# writes). When BOTH env vars are supplied (unsupported per the one-variable
|
|
1012
|
+
# contract), SPEC_PATH wins and a startup warning is logged.
|
|
1013
|
+
if _spec_path_supplied and _dispatched_supplied:
|
|
1014
|
+
_log.warning(
|
|
1015
|
+
"Both WORKSPACE_MCP_SPEC_PATH and WORKSPACE_MCP_DISPATCHED_ITEM are set "
|
|
1016
|
+
"(unsupported); WORKSPACE_MCP_SPEC_PATH takes precedence — "
|
|
1017
|
+
"FSM mode active, git writes blocked"
|
|
1018
|
+
)
|
|
1019
|
+
self._fsm_mode = _spec_path_supplied
|
|
995
1020
|
# Expected branch from dispatched item (ini_slug/type:slug → ini_slug/type/slug)
|
|
996
1021
|
self._expected_branch: str | None = self._derive_expected_branch(dispatched)
|
|
997
1022
|
self._session_branch: str | None = self._read_head_branch()
|
|
@@ -1006,10 +1031,10 @@ class _GitTools:
|
|
|
1006
1031
|
# Case 1: resumed dispatched session
|
|
1007
1032
|
(self._expected_branch is not None
|
|
1008
1033
|
and self._session_branch == self._expected_branch)
|
|
1009
|
-
# Case 2: FSM
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1034
|
+
# Case 2: FSM mode (SPEC_PATH supplied); lock to startup HEAD so the
|
|
1035
|
+
# session cannot redirect git_push to an arbitrary caller-chosen ref.
|
|
1036
|
+
# _fsm_mode blocks mutating tools anyway; this lock is belt-and-suspenders.
|
|
1037
|
+
or (_spec_path_supplied and self._session_branch is not None)
|
|
1013
1038
|
)
|
|
1014
1039
|
# Serialize all mutating git operations: prevents index.lock collisions
|
|
1015
1040
|
# and TOCTOU races on _session_branch between concurrent tool calls.
|
|
@@ -1256,6 +1281,15 @@ class _GitTools:
|
|
|
1256
1281
|
return {"output": r.stdout, "returncode": r.returncode}
|
|
1257
1282
|
|
|
1258
1283
|
def git_branch(self, arguments: dict) -> dict:
|
|
1284
|
+
# FSM guard precedes discovery-mode guard (fail-closed: SPEC_PATH="" is FSM,
|
|
1285
|
+
# not discovery mode, so _fsm_mode fires before _discovery_mode can).
|
|
1286
|
+
if self._fsm_mode:
|
|
1287
|
+
return {
|
|
1288
|
+
"error": (
|
|
1289
|
+
"git_branch is not available in work-loop (FSM) mode — "
|
|
1290
|
+
"work-loop manages its own git lifecycle"
|
|
1291
|
+
)
|
|
1292
|
+
}
|
|
1259
1293
|
if self._discovery_mode:
|
|
1260
1294
|
return {"error": "git_branch is not available in discovery mode"}
|
|
1261
1295
|
name = arguments.get("name", "")
|
|
@@ -1301,6 +1335,13 @@ class _GitTools:
|
|
|
1301
1335
|
return {"branch": name}
|
|
1302
1336
|
|
|
1303
1337
|
def git_commit(self, arguments: dict) -> dict:
|
|
1338
|
+
if self._fsm_mode:
|
|
1339
|
+
return {
|
|
1340
|
+
"error": (
|
|
1341
|
+
"git_commit is not available in work-loop (FSM) mode — "
|
|
1342
|
+
"work-loop manages its own git lifecycle"
|
|
1343
|
+
)
|
|
1344
|
+
}
|
|
1304
1345
|
if self._discovery_mode:
|
|
1305
1346
|
return {"error": "git_commit is not available in discovery mode"}
|
|
1306
1347
|
message = arguments.get("message", "workspace-mcp: commit artifacts")
|
|
@@ -1411,6 +1452,13 @@ class _GitTools:
|
|
|
1411
1452
|
return {"committed": matched, "message": message}
|
|
1412
1453
|
|
|
1413
1454
|
def git_push(self, arguments: dict) -> dict:
|
|
1455
|
+
if self._fsm_mode:
|
|
1456
|
+
return {
|
|
1457
|
+
"error": (
|
|
1458
|
+
"git_push is not available in work-loop (FSM) mode — "
|
|
1459
|
+
"work-loop manages its own git lifecycle"
|
|
1460
|
+
)
|
|
1461
|
+
}
|
|
1414
1462
|
if self._discovery_mode:
|
|
1415
1463
|
return {"error": "git_push is not available in discovery mode"}
|
|
1416
1464
|
branch = arguments.get("branch", "")
|
|
@@ -1553,15 +1601,31 @@ class _StdioLoop:
|
|
|
1553
1601
|
"Returns the current workspace queue and active-run state. "
|
|
1554
1602
|
"Call this at session start before doing any work. "
|
|
1555
1603
|
"Response fields: "
|
|
1556
|
-
"ready[] — items that
|
|
1604
|
+
"ready[] — items that may be dispatchable, each with "
|
|
1557
1605
|
"ini_slug, type, slug, and dispatch_skill; "
|
|
1558
|
-
"
|
|
1606
|
+
"dispatchable items omit the 'available' field (treat absent as eligible); "
|
|
1607
|
+
"items where available=false require an optional pack (see required_pack); "
|
|
1608
|
+
"items with a non-empty unmet_needs list have unresolved dependencies; "
|
|
1609
|
+
"only dispatch items where 'available' is absent (not false) and "
|
|
1610
|
+
"'unmet_needs' is absent or empty; "
|
|
1611
|
+
"blocked[] — items whose dependency needs are not yet met; "
|
|
1559
1612
|
"active[] — items currently in progress; "
|
|
1560
|
-
"shaping[] — non-
|
|
1561
|
-
"
|
|
1562
|
-
"
|
|
1613
|
+
"shaping[] — informational only in Stage 1; non-FSM items (research, design, "
|
|
1614
|
+
"shape, strategy) whose skill flows are not yet shipped (Stage 3); "
|
|
1615
|
+
"do not dispatch shaping items in Stage 1 — selecting one opens a bound "
|
|
1616
|
+
"session with no usable skill flow; same available/required_pack/unmet_needs "
|
|
1617
|
+
"fields as ready[] for readiness visibility; "
|
|
1618
|
+
"current_state — current work-loop phase name (null when idle OR when this "
|
|
1619
|
+
"session is not bound to a valid spec — see below); "
|
|
1620
|
+
"gate_pending — true when human input is required before work can continue "
|
|
1621
|
+
"(always false when not spec-bound); "
|
|
1563
1622
|
"gate — name of the pending gate (e.g. SPEC-HUMAN-GATE, REVIEW-HUMAN-GATE); "
|
|
1564
|
-
"gate_question — the specific question the work-loop is asking."
|
|
1623
|
+
"gate_question — the specific question the work-loop is asking. "
|
|
1624
|
+
"IMPORTANT: current_state, gate_pending, gate, and gate_question are "
|
|
1625
|
+
"authoritative only in a session where WORKSPACE_MCP_SPEC_PATH is set to "
|
|
1626
|
+
"a valid spec directory; in discovery sessions (no SPEC_PATH) or sessions "
|
|
1627
|
+
"with an invalid SPEC_PATH these fields are always null/false even if a "
|
|
1628
|
+
"work-loop is active in another session."
|
|
1565
1629
|
),
|
|
1566
1630
|
"inputSchema": {"type": "object", "properties": {}},
|
|
1567
1631
|
},
|
|
@@ -1602,6 +1666,7 @@ class _StdioLoop:
|
|
|
1602
1666
|
{
|
|
1603
1667
|
"name": "git_status",
|
|
1604
1668
|
"description": (
|
|
1669
|
+
"Use this instead of running 'git status' directly. "
|
|
1605
1670
|
"Returns uncommitted file changes in the repo "
|
|
1606
1671
|
"(equivalent to git status --short). "
|
|
1607
1672
|
"Returns {output: string, returncode: int}."
|
|
@@ -1611,11 +1676,15 @@ class _StdioLoop:
|
|
|
1611
1676
|
{
|
|
1612
1677
|
"name": "git_branch",
|
|
1613
1678
|
"description": (
|
|
1614
|
-
"
|
|
1679
|
+
"Use this instead of running 'git checkout -b' directly — "
|
|
1680
|
+
"raw git branch commands bypass the scoping guard that locks "
|
|
1681
|
+
"the session to exactly one branch for the dispatched item. "
|
|
1682
|
+
"Creates and checks out a new feature branch. "
|
|
1615
1683
|
"The branch name must follow the ini_slug/type/slug format "
|
|
1616
|
-
"(e.g. my-initiative/
|
|
1684
|
+
"(e.g. my-initiative/shape/new-feature) and must match the dispatched item. "
|
|
1617
1685
|
"May only be called once per session; subsequent calls are rejected. "
|
|
1618
|
-
"Not available
|
|
1686
|
+
"Not available in FSM/work-loop sessions (WORKSPACE_MCP_SPEC_PATH set) "
|
|
1687
|
+
"or when no item has been dispatched."
|
|
1619
1688
|
),
|
|
1620
1689
|
"inputSchema": {
|
|
1621
1690
|
"type": "object",
|
|
@@ -1624,7 +1693,7 @@ class _StdioLoop:
|
|
|
1624
1693
|
"type": "string",
|
|
1625
1694
|
"description": (
|
|
1626
1695
|
"Branch name in ini_slug/type/slug format "
|
|
1627
|
-
"(e.g. my-initiative/
|
|
1696
|
+
"(e.g. my-initiative/shape/new-feature)."
|
|
1628
1697
|
),
|
|
1629
1698
|
}
|
|
1630
1699
|
},
|
|
@@ -1634,9 +1703,13 @@ class _StdioLoop:
|
|
|
1634
1703
|
{
|
|
1635
1704
|
"name": "git_commit",
|
|
1636
1705
|
"description": (
|
|
1637
|
-
"
|
|
1638
|
-
"
|
|
1639
|
-
"files outside
|
|
1706
|
+
"Use this instead of running 'git add' and 'git commit' directly — "
|
|
1707
|
+
"raw git commit bypasses the output-path filter and may silently "
|
|
1708
|
+
"include files outside the dispatched item's scope. "
|
|
1709
|
+
"Stages and commits only files under the item's configured output "
|
|
1710
|
+
"paths; unstaged files outside those paths are excluded automatically. "
|
|
1711
|
+
"If any files outside the output paths are already pre-staged (via "
|
|
1712
|
+
"git add), the commit is refused — unstage them first. "
|
|
1640
1713
|
"Not available when no item has been dispatched, or for work-loop "
|
|
1641
1714
|
"items (work-loop manages its own git lifecycle)."
|
|
1642
1715
|
),
|
|
@@ -1656,9 +1729,16 @@ class _StdioLoop:
|
|
|
1656
1729
|
{
|
|
1657
1730
|
"name": "git_push",
|
|
1658
1731
|
"description": (
|
|
1659
|
-
"
|
|
1660
|
-
"
|
|
1661
|
-
"
|
|
1732
|
+
"Use this instead of running 'git push' directly — "
|
|
1733
|
+
"raw git push bypasses the branch check that prevents pushing "
|
|
1734
|
+
"to a branch other than the one established for this session. "
|
|
1735
|
+
"Pushes the session branch to origin. "
|
|
1736
|
+
"The session branch must be established before pushing: "
|
|
1737
|
+
"call git_branch() in a new session, or in a resumed "
|
|
1738
|
+
"dispatched session the branch may already be locked from "
|
|
1739
|
+
"the prior run (no git_branch() call required in that case). "
|
|
1740
|
+
"Not available in FSM/work-loop sessions (WORKSPACE_MCP_SPEC_PATH set) "
|
|
1741
|
+
"or when no item has been dispatched."
|
|
1662
1742
|
),
|
|
1663
1743
|
"inputSchema": {
|
|
1664
1744
|
"type": "object",
|
|
@@ -1666,8 +1746,9 @@ class _StdioLoop:
|
|
|
1666
1746
|
"branch": {
|
|
1667
1747
|
"type": "string",
|
|
1668
1748
|
"description": (
|
|
1669
|
-
"Branch name to push. Must match the
|
|
1670
|
-
"established by git_branch()
|
|
1749
|
+
"Branch name to push. Must match the session-bound "
|
|
1750
|
+
"branch established by git_branch() or inherited "
|
|
1751
|
+
"from session startup."
|
|
1671
1752
|
),
|
|
1672
1753
|
}
|
|
1673
1754
|
},
|