Skip to content

Add battery pack integration for skill matching#235

Open
nikomatsakis wants to merge 5 commits into
symposium-dev:mainfrom
nikomatsakis:batttery-pack-integration
Open

Add battery pack integration for skill matching#235
nikomatsakis wants to merge 5 commits into
symposium-dev:mainfrom
nikomatsakis:batttery-pack-integration

Conversation

@nikomatsakis
Copy link
Copy Markdown
Member

What does this PR do?

Battery packs are crate bundles managed by cargo bp rather than declared as normal Cargo dependencies. Plugins can now reference them in predicates (e.g. crates = ["cli-battery-pack"]) and symposium will discover installed packs by acquiring the cargo-bp binary into its cache and running cargo bp status --json.

The discovery is gracefully skipped when cargo-bp is unavailable, so projects without battery packs see no change in behavior.

Disclosure questions

AI disclosure.

  • The AI tool authored large parts of the code

Questions for reviewers.

@nikomatsakis nikomatsakis marked this pull request as ready for review May 31, 2026 19:56
Copy link
Copy Markdown
Member

@jlizen jlizen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good overall, I haven't tested it end to end, I assume you have.

Comment thread src/sync.rs Outdated
Comment thread src/crate_sources/battery_pack.rs Outdated
Comment thread tests/init_sync.rs
Comment thread src/crate_sources/battery_pack.rs Outdated
@nikomatsakis nikomatsakis force-pushed the batttery-pack-integration branch from 54033e5 to becbb18 Compare June 1, 2026 14:53
nikomatsakis and others added 4 commits June 3, 2026 23:10
Battery packs are crate bundles managed by `cargo bp` rather than
declared as normal Cargo dependencies. Plugins can now reference them
in predicates (e.g. `crates = ["cli-battery-pack"]`) and symposium
will discover installed packs by acquiring the `cargo-bp` binary into
its cache and running `cargo bp status --json`.

The discovery is gracefully skipped when `cargo-bp` is unavailable,
so projects without battery packs see no change in behavior.

Co-authored-by: Claude <claude@anthropic.com>
- Use `normalize_crate_name` when deduplicating battery packs against
  workspace crates (hyphen/underscore insensitivity)
- Destructure `AcquiredSource` after await instead of `.map()` on Result
- Wrap `StatusCommand::run()` in `spawn_blocking` to avoid blocking
  the async runtime
- Add integration test for graceful degradation when cargo-bp is
  unavailable

Co-authored-by: Claude <claude@anthropic.com>
@nikomatsakis nikomatsakis force-pushed the batttery-pack-integration branch from 7e414fd to 22baa0c Compare June 4, 2026 00:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants