Skip to content

chore(deps): upgrade cpal from 0.15.3 (fork) to 0.17.1 (official)#2088

Open
louis030195 wants to merge 1 commit intomainfrom
upgrade-cpal-0.17
Open

chore(deps): upgrade cpal from 0.15.3 (fork) to 0.17.1 (official)#2088
louis030195 wants to merge 1 commit intomainfrom
upgrade-cpal-0.17

Conversation

@louis030195
Copy link
Collaborator

Summary

  • Upgrades cpal from Kree0/cpal fork (0.15.3) to official cpal 0.17.1
  • Upgrades deepgram from 0.6.4 to 0.7.0 (resolves rodio/cpal version conflict)
  • Removes ScreenCaptureKit host workaround - cpal 0.17+ has native loopback support

Why this matters

  • No more fork dependency - Using official cpal means better maintenance and updates
  • Native macOS loopback - cpal 0.17+ supports recording system audio on macOS 14.2+ natively
  • Cleaner codebase - Removed ~370 lines of ScreenCaptureKit workaround code

API changes in cpal 0.17

  • sample_rate() returns u32 directly (was SampleRate struct with .0 field)
  • device.name() deprecated in favor of device.description() (kept for compat, shows warnings)

macOS loopback recording

Before (Kree0 fork) After (cpal 0.17)
Separate ScreenCaptureKit host Native CoreAudio loopback
macOS 14+ macOS 14.2+
Custom retry logic needed Built-in aggregate device

Test plan

  • cargo build -p screenpipe-audio passes
  • cargo build -p screenpipe-server passes
  • cargo test -p screenpipe-audio passes
  • CI builds pass on macOS, Linux, Windows
  • Manual test: loopback audio capture on macOS 14.2+

Breaking changes

  • Requires macOS 14.2+ for loopback (was 14.0+)
  • If users relied on ScreenCaptureKit host ID, that's removed

🤖 Generated with Claude Code

Breaking changes addressed:
- cpal: Kree0/cpal fork (0.15.3) -> official cpal 0.17.1
- deepgram: 0.6.4 -> 0.7.0 (removes rodio/cpal 0.15 conflict)

API changes:
- sample_rate() now returns u32 directly (removed .0 field access)
- max_sample_rate() now returns u32 directly
- Removed ScreenCaptureKit host usage (cpal 0.17 has native loopback)

macOS loopback recording:
- cpal 0.17+ supports loopback recording natively on macOS 14.2+
- No longer need separate ScreenCaptureKit host from fork
- Uses CoreAudio aggregate device internally

Note: device.name() is deprecated in favor of device.description()
but kept for backwards compatibility (shows warnings, not errors)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant