⚠ This page is served via a proxy. Original site: https://github.com
This service does not collect credentials or authentication data.
Skip to content

Conversation

@tschellenbach
Copy link
Member

@tschellenbach tschellenbach commented Jan 12, 2026

remove torch since we only use it for dev.

Summary by CodeRabbit

  • Chores
    • Reduced default install size by moving machine-learning and audio libraries to development-only dependencies.
    • Pinned the multimedia backend to a specific compatible release to improve installation reliability with prebuilt wheels.
    • Kept ML/audio libraries in dev dependencies for development scripts and asset creation.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link

coderabbitai bot commented Jan 12, 2026

📝 Walkthrough

Walkthrough

Updated pyproject.toml: removed torch and torchaudio from the webrtc optional-dependencies, added av>=14.0.0,<14.3 to webrtc, and placed torch>=2.7.0 and torchaudio>=2.7.0 into the dev dependency group with a note they are only used by scripts/create_test_assets.py. (50 words)

Changes

Cohort / File(s) Summary
Dependency reorganization
pyproject.toml
Removed torch>=2.7.0 and torchaudio>=2.7.0 from the webrtc optional-dependencies; added av>=14.0.0,<14.3 to webrtc; added torch>=2.7.0 and torchaudio>=2.7.0 to the dev dependency group with a note they are only used by scripts/create_test_assets.py.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Poem

🐰 I hopped through deps with nimble feet,

Torch tucked to dev where scripts will meet,
AV set to fourteenth's gate,
A tidy change — now all is straight,
I twitch my nose and skip a beat. 🥕

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the main change: removing PyTorch from main dependencies and moving it to dev-only dependencies. It clearly conveys the primary objective of the PR.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
pyproject.toml (1)

37-56: Consider cleaning up duplicate dependencies in the webrtc group.

While not part of this change, there are several duplicate entries in the webrtc optional-dependencies that could cause confusion:

Package Line 1 Line 2
numpy >=2.2.6,<2.3 (39) >=2.2.6 (48)
scipy >=1.15.3,<1.16 (41) >=1.15.3 (50)
protobuf >=4.25.1 (43) >=6.31.1 (53)
websockets >=15.0.1,<16 (44) >=15.0.1 (54)
websocket-client >=1.8.0 (45) >=1.8.0 (55)

The protobuf versions are notably inconsistent (4.25.1 vs 6.31.1). You may want to consolidate these in a follow-up.

📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 8fd58ac and a484c42.

⛔ Files ignored due to path filters (1)
  • uv.lock is excluded by !**/*.lock
📒 Files selected for processing (1)
  • pyproject.toml
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: CR
Repo: GetStream/stream-py PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-02T12:16:57.243Z
Learning: Applies to **/*.py : Plugins that work with audio, video, or WebRTC functionality should depend on `getstream[webrtc]` instead of just `getstream` to access WebRTC-related dependencies like `aiortc`, `numpy`, `torch`, `torchaudio`, `soundfile`, `scipy`, `deepgram-sdk`, and `elevenlabs`
📚 Learning: 2025-12-02T12:16:57.243Z
Learnt from: CR
Repo: GetStream/stream-py PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-02T12:16:57.243Z
Learning: Applies to **/*.py : Plugins that work with audio, video, or WebRTC functionality should depend on `getstream[webrtc]` instead of just `getstream` to access WebRTC-related dependencies like `aiortc`, `numpy`, `torch`, `torchaudio`, `soundfile`, `scipy`, `deepgram-sdk`, and `elevenlabs`

Applied to files:

  • pyproject.toml
🔇 Additional comments (1)
pyproject.toml (1)

82-83: The placement of torch and torchaudio in dev dependencies is correct. These packages are not—and have never been—part of the webrtc optional-dependencies, so moving them here is not a breaking change. They are only used in scripts/create_test_assets.py, and the comment appropriately documents this limitation.

Likely an incorrect or invalid review comment.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
pyproject.toml (1)

40-56: Pre-existing duplicate dependencies with conflicting versions.

The webrtc extras contain duplicate entries with inconsistent version constraints:

Package First occurrence Second occurrence
numpy >=2.2.6,<2.3 (line 40) >=2.2.6 (line 49)
protobuf >=4.25.1 (line 44) >=6.31.1 (line 54)
scipy >=1.15.3,<1.16 (line 42) >=1.15.3 (line 51)
websockets >=15.0.1,<16 (line 45) >=15.0.1 (line 55)
websocket-client >=1.8.0 (lines 46, 56)

The protobuf conflict (>=4.25.1 vs >=6.31.1) is particularly problematic. Consider consolidating these in a follow-up.

📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 04719ba and a64bc94.

⛔ Files ignored due to path filters (1)
  • uv.lock is excluded by !**/*.lock
📒 Files selected for processing (1)
  • pyproject.toml
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: CR
Repo: GetStream/stream-py PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-02T12:16:57.243Z
Learning: Applies to **/*.py : Plugins that work with audio, video, or WebRTC functionality should depend on `getstream[webrtc]` instead of just `getstream` to access WebRTC-related dependencies like `aiortc`, `numpy`, `torch`, `torchaudio`, `soundfile`, `scipy`, `deepgram-sdk`, and `elevenlabs`
📚 Learning: 2025-12-02T12:16:57.243Z
Learnt from: CR
Repo: GetStream/stream-py PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-02T12:16:57.243Z
Learning: Applies to **/*.py : Plugins that work with audio, video, or WebRTC functionality should depend on `getstream[webrtc]` instead of just `getstream` to access WebRTC-related dependencies like `aiortc`, `numpy`, `torch`, `torchaudio`, `soundfile`, `scipy`, `deepgram-sdk`, and `elevenlabs`

Applied to files:

  • pyproject.toml
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: unit / Test "not integration"
  • GitHub Check: unit / Test "not integration"
  • GitHub Check: unit / Test "not integration"
  • GitHub Check: unit / Test "not integration"
  • GitHub Check: unit / Test "not integration"
  • GitHub Check: unit / Test "not integration"
  • GitHub Check: unit / Test "not integration"
  • GitHub Check: unit / Test "not integration"
🔇 Additional comments (2)
pyproject.toml (2)

83-84: No breaking change — torch and torchaudio are correctly placed in dev dependencies.

Verification confirms that torch and torchaudio are used exclusively in scripts/create_test_assets.py and not in any runtime webrtc code. Moving these to dev dependencies is safe and appropriate.

Likely an incorrect or invalid review comment.


39-39: LGTM. Pinning av>=14.0.0,<14.3 to versions with pre-built wheels is sound.

Both av 14.0.0 (Dec 2024) and av 14.2.0 (Feb 2025, latest in 14.x) have prebuilt wheels available for CPython 3.9–3.13 across Windows, macOS, and manylinux platforms. The version constraint successfully targets the intended range and avoids build-time compilation issues.

@tschellenbach tschellenbach merged commit 0210d14 into main Jan 12, 2026
15 of 16 checks passed
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