Skip to content

Conversation

@Brazol
Copy link
Contributor

@Brazol Brazol commented Dec 30, 2025

Summary by CodeRabbit

  • New Features

    • Added enhanced RTP metrics message types for richer inbound/outbound/remote metrics.
    • Introduced a SendMetrics RPC for submitting session metrics.
    • Added a new client capability for coordinator stats.
  • Chores

    • Bumped dependencies (device_info_plus, http, protobuf, uuid, thermal, internet_connection_checker_plus, protoc_plugin).

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

@Brazol Brazol requested a review from a team as a code owner December 30, 2025 15:42
@coderabbitai
Copy link

coderabbitai bot commented Dec 30, 2025

📝 Walkthrough

Walkthrough

This PR bumps multiple package versions, regenerates protobuf Dart files (removing many static createRepeated() helpers), adds RTP message types (RtpBase, InboundRtp, OutboundRtp, RemoteInboundRtp, RemoteOutboundRtp), and introduces a new SendMetrics RPC with request/response types wired into SignalServer.

Changes

Cohort / File(s) Summary
Dependency Version Updates
dogfooding/pubspec.yaml, melos.yaml, packages/stream_video/pubspec.yaml, packages/stream_video_flutter/example/pubspec.yaml, packages/stream_video_push_notification/pubspec.yaml
Bumped dependency versions (e.g., device_info_plus ^12.1.0→^12.3.0, http → ^1.6.0, protobuf → ^6.0.0, uuid → ^4.5.2, protoc_plugin → ^25.0.0). Added uuid to melos bootstrap.
Event protobufs (generated)
packages/stream_video/lib/protobuf/video/sfu/event/events.pb.dart, .../events.pbenum.dart, .../events.pbjson.dart
Removed many static createRepeated() helpers from GeneratedMessage classes; updated lint ignore to include prefer_relative_imports.
Model protobufs (generated)
packages/stream_video/lib/protobuf/video/sfu/models/models.pb.dart, .../models.pbenum.dart, .../models.pbjson.dart
Added RTP message types (RtpBase, InboundRtp, OutboundRtp, RemoteInboundRtp, RemoteOutboundRtp) and updated descriptors; removed numerous createRepeated() helpers; added enum value CLIENT_CAPABILITY_COORDINATOR_STATS.
Signal RPC protobufs & server/client bindings (generated)
packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pb.dart, .../signal.pbenum.dart, .../signal.pbjson.dart, .../signal.pbserver.dart, .../signal.pbtwirp.dart
Added SendMetricsRequest/SendMetricsResponse messages and wired new SendMetrics RPC into SignalServer (server base, Twirp JSON/Protobuf clients). Removed many createRepeated() helpers; updated lint ignore to include prefer_relative_imports.

Sequence Diagram(s)

(omitted)

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Suggested reviewers

  • renefloor
  • xsahil03x

Poem

🐰 Hopped in from the burrow, bright and quick—
New RTP seeds, a SendMetrics trick.
Protobuf fields sprout, lists trimmed with care,
Versions updated, fresh code in the air.
Metrics bloom, I nibble a carrot and cheer! 🥕✨

Pre-merge checks

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Description check ⚠️ Warning The pull request description is empty; no content was provided by the author despite a detailed template being available requiring Goal, Implementation details, Testing explanation, and Contributor Checklist. Add a comprehensive description following the template: explain why dependencies and protobuf files are being updated, document implementation details, describe testing approach, and complete the Contributor Checklist items.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title 'chore(repo): dependencies and proto update' clearly and specifically describes the main changes: dependency version bumps and protobuf code regeneration across multiple packages.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

📜 Recent 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 cfa60c9 and 9af9b44.

📒 Files selected for processing (1)
  • packages/stream_video/pubspec.yaml
🚧 Files skipped from review as they are similar to previous changes (1)
  • packages/stream_video/pubspec.yaml
⏰ 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: analyze_legacy_version
  • GitHub Check: stream_video
  • GitHub Check: stream_video_noise_cancellation
  • GitHub Check: stream_video_push_notification
  • GitHub Check: stream_video_flutter
  • GitHub Check: iOS Build (Dogfooding)
  • GitHub Check: build
  • GitHub Check: analyze

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: 1

📜 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 c27e581 and cfa60c9.

📒 Files selected for processing (16)
  • dogfooding/pubspec.yaml
  • melos.yaml
  • packages/stream_video/lib/protobuf/video/sfu/event/events.pb.dart
  • packages/stream_video/lib/protobuf/video/sfu/event/events.pbenum.dart
  • packages/stream_video/lib/protobuf/video/sfu/event/events.pbjson.dart
  • packages/stream_video/lib/protobuf/video/sfu/models/models.pb.dart
  • packages/stream_video/lib/protobuf/video/sfu/models/models.pbenum.dart
  • packages/stream_video/lib/protobuf/video/sfu/models/models.pbjson.dart
  • packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pb.dart
  • packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pbenum.dart
  • packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pbjson.dart
  • packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pbserver.dart
  • packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pbtwirp.dart
  • packages/stream_video/pubspec.yaml
  • packages/stream_video_flutter/example/pubspec.yaml
  • packages/stream_video_push_notification/pubspec.yaml
⏰ 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). (5)
  • GitHub Check: stream_video
  • GitHub Check: stream_video_noise_cancellation
  • GitHub Check: stream_video_push_notification
  • GitHub Check: stream_video_flutter
  • GitHub Check: iOS Build (Dogfooding)
🔇 Additional comments (21)
dogfooding/pubspec.yaml (1)

15-15: LGTM! Dependency version bumps look good.

The minor version bumps for device_info_plus (^12.1.0 → ^12.3.0) and http (^1.5.0 → ^1.6.0) are consistent with the coordinated updates across the monorepo.

Also applies to: 30-30

packages/stream_video_flutter/example/pubspec.yaml (1)

16-16: LGTM! Dependency updates are consistent with the monorepo.

The version bumps for device_info_plus and http align with the coordinated updates across other pubspec files.

Also applies to: 25-25

packages/stream_video_push_notification/pubspec.yaml (1)

27-27: LGTM! Patch version bump is safe.

The uuid dependency patch update (^4.5.1 → ^4.5.2) aligns with the coordinated updates across the monorepo.

melos.yaml (1)

22-23: LGTM! Bootstrap dependency updates ensure consistency.

The device_info_plus version bump and addition of uuid to bootstrap dependencies ensure consistent versions across all packages in the monorepo.

packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pbenum.dart (1)

11-11: LGTM! Generated code update.

The lint directive update in this generated protobuf file is expected and aligns with the protobuf tooling updates.

packages/stream_video/pubspec.yaml (1)

19-19: LGTM! Minor and patch version bumps are safe.

The updates to device_info_plus, http, internet_connection_checker_plus, meta, thermal, and uuid are minor or patch version bumps that should maintain backward compatibility.

Also applies to: 24-25, 28-28, 38-39

packages/stream_video/lib/protobuf/video/sfu/event/events.pbenum.dart (1)

11-11: LGTM! Generated code update.

The lint directive update is expected from the protobuf tooling updates.

packages/stream_video/lib/protobuf/video/sfu/event/events.pbjson.dart (1)

11-12: LGTM! Generated code update.

The lint directive updates in this generated protobuf file are expected and align with the protobuf tooling updates.

packages/stream_video/lib/protobuf/video/sfu/models/models.pbenum.dart (1)

542-554: LGTM! New client capability properly added.

The CLIENT_CAPABILITY_COORDINATOR_STATS enum value is correctly declared with index 2, added to the values list, and the _initByValueList base parameter is appropriately updated from 1 to 2 to reflect the new maximum enum value.

packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pbserver.dart (1)

39-40: LGTM! SendMetrics RPC properly integrated.

The new sendMetrics method is correctly added to the SignalServerServiceBase with:

  • Abstract method signature (lines 39-40)
  • Request factory case (lines 62-63)
  • Handler dispatch case (lines 91-92)

The implementation follows the established pattern of other RPC methods in the service.

Also applies to: 62-63, 91-92

packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pbtwirp.dart (1)

42-45: LGTM! Client implementations correctly generated.

The sendMetrics RPC is properly implemented in both client variants:

  • Interface declaration (lines 42-45)
  • JSON client implementation (lines 293-321)
  • Protobuf client implementation (lines 625-653)

Both implementations correctly follow the established pattern with context setup, interceptor integration, and appropriate response handling.

Also applies to: 293-321, 625-653

packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pbjson.dart (1)

145-210: LGTM! SendMetrics descriptors and service mappings correctly added.

The JSON descriptors for the new RPC are comprehensive:

  • SendMetricsRequest with 6 fields including repeated RTP message types (lines 145-201)
  • SendMetricsResponse as empty message (lines 203-210)
  • Service definition updated (lines 713-717)
  • Message type mappings added for all new types (lines 767-773)
  • Service descriptor updated (lines 800-806)

Also applies to: 713-717, 767-773, 800-806

packages/stream_video/lib/protobuf/video/sfu/models/models.pbjson.dart (2)

315-315: LGTM! ClientCapability enum updated in JSON descriptors.

The new CLIENT_CAPABILITY_COORDINATOR_STATS enum value is correctly added to the JSON definition (line 315) and the corresponding base64-encoded descriptor is updated (lines 320-323).

Also applies to: 320-323


1119-1277: LGTM! New RTP message type descriptors properly defined.

The new RTP-related message types are correctly added with complete JSON field definitions and base64-encoded descriptors:

  • RtpBase - base message with ssrc, kind, and timestamp fields
  • InboundRtp - inbound metrics with jitter, packets, loss, concealment, fps, freeze duration, decode time, etc.
  • OutboundRtp - outbound metrics with fps, encode time, bitrate, dimension
  • RemoteInboundRtp - remote inbound with jitter and RTT
  • RemoteOutboundRtp - remote outbound with jitter and RTT

These message types support the new SendMetricsRequest payload structure.

packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pb.dart (3)

414-507: LGTM! SendMetricsRequest class properly generated.

The SendMetricsRequest class is complete with:

  • Factory constructor accepting all 6 fields (sessionId, unifiedSessionId, and 4 repeated RTP message lists)
  • Proper BuilderInfo configuration with field tags and sub-builders
  • All required accessors using $_getList for repeated fields
  • Standard clone/copyWith/create methods

509-546: LGTM! SendMetricsResponse class correctly generated.

The SendMetricsResponse class is properly defined as an empty message with all required boilerplate methods (factory, fromBuffer, fromJson, clone, copyWith, etc.).


1960-1963: LGTM! SignalServerApi.sendMetrics method correctly added.

The sendMetrics method is properly integrated into the SignalServerApi class, following the same pattern as other RPC methods with correct method name, request/response types, and client invocation.

packages/stream_video/lib/protobuf/video/sfu/models/models.pb.dart (3)

11-11: Lint suppression update for generated file is appropriate

Adding prefer_relative_imports to the ignore_for_file list is fine for generated code and keeps analyzer lints out of these files.


15-19: New fixnum / well‑known type imports match usage

The added fixnum import and the switched struct.pb.dart / timestamp.pb.dart imports under package:protobuf/well_known_types/... align with how $fixnum.Int64, $1.Struct, and $0.Timestamp are used later in this file. Just ensure the protobuf package version in pubspec.yaml matches the generator that emits these paths so builds stay green.


2563-3110: RTP metrics message definitions look structurally sound

The new RtpBase, InboundRtp, OutboundRtp, RemoteInboundRtp, and RemoteOutboundRtp messages have consistent tag numbers, field indices, and types (e.g., Int64 for packet counters, unsigned ints for pixel dimensions, doubles for timing/percent values). This should serialize/deserialize correctly and gives a good foundation for RTP stats in all directions.

packages/stream_video/lib/protobuf/video/sfu/event/events.pb.dart (1)

11-11: Additional lint suppression is harmless for this generated file

Including prefer_relative_imports in the ignore_for_file header is consistent with treating this as generated code and has no runtime impact.

meta: ^1.17.0
package_info_plus: ^9.0.0
protobuf: ^5.0.0
protobuf: ^6.0.0
Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

# First, find and check the pubspec.yaml file to confirm the versions
find . -name "pubspec.yaml" -path "*/stream_video/*" | head -5

Repository: GetStream/stream-video-flutter

Length of output: 110


🏁 Script executed:

# Check the content of the relevant pubspec.yaml
cat packages/stream_video/pubspec.yaml | grep -A 2 -B 2 "protobuf\|protoc_plugin"

Repository: GetStream/stream-video-flutter

Length of output: 268


🏁 Script executed:

# Look for any proto files in the stream_video package
find packages/stream_video -name "*.proto" -o -name "*pb2.dart" -o -name "*pb.dart" | head -20

Repository: GetStream/stream-video-flutter

Length of output: 811


🌐 Web query:

What are the breaking changes in protobuf Dart package version 6.0.0 compared to 5.0.0?

💡 Result:

Breaking changes in protobuf 6.0.0 (vs. 5.x):

  • PbList and PbMap constructors are now hidden (made private). You can no longer construct PbList/PbMap directly; replace with Dart List/Map (or use built_value for immutable collections). [1]
  • Map fields now validate keys and values when adding elements; code that previously inserted invalid keys/values into map fields may now fail. [1]

(Other 6.0.0 changes: new GeneratedMessage.toTextFormat/writeTextFormat and adding well‑known proto types — these are non‑breaking.) [2]

Sources:
[1] protobuf CHANGELOG (6.0.0).
[2] pub.dev protobuf changelog (6.0.0).


🌐 Web query:

What are the breaking changes in protoc_plugin Dart package version 25.0.0 compared to 23.0.0?

💡 Result:

Short answer — main breaking changes between protoc_plugin 23.0.0 and 25.0.0:

  1. protoc_plugin 24.0.0 removed generation of createRepeated() methods — migrate MyMessage.createRepeated() → []. [1]

  2. protoc_plugin 25.0.0 bumps the required package:protobuf version (needs protobuf 5.2.0). Upgrading to protobuf 5.x introduces its own breaking changes you must follow (notably PbList/PbMap constructors were made private and other runtime checks/behavior changes). Replace direct PbList/PbMap construction with plain List/Map (or use an immutable library for immutable collections). [1][2]

  3. protoc_plugin 25.0.0: generated code now handles importing well-known protos (behavior change in imports/aliases). This is not a removal, but may change generated import statements and require adjusting import usage. [1]

Sources: protoc_plugin changelog and protobuf changelog. [1][2]

References
[1] protoc_plugin changelog (versions 23.0.0–25.0.0).
[2] protobuf package changelog (notes on PbList/PbMap and well-known types).


🏁 Script executed:

# Search for PbList or PbMap constructor usage
rg "PbList\s*\(|PbMap\s*\(" packages/stream_video/lib/ --type dart

Repository: GetStream/stream-video-flutter

Length of output: 56


🏁 Script executed:

# Search for createRepeated() method calls
rg "\.createRepeated\(" packages/stream_video/lib/ --type dart

Repository: GetStream/stream-video-flutter

Length of output: 56


🏁 Script executed:

# Search for direct List/Map usage patterns that might need attention
rg "PbList|PbMap" packages/stream_video/lib/ --type dart -A 2 -B 2

Repository: GetStream/stream-video-flutter

Length of output: 22577


🏁 Script executed:

# Check generated .pb.dart files for potential issues
head -100 packages/stream_video/lib/protobuf/video/sfu/signal_rpc/signal.pb.dart

Repository: GetStream/stream-video-flutter

Length of output: 3877


Generated protobuf code must be regenerated with protoc_plugin 25.0.0.

The major version bumps introduce breaking changes that require regenerating the .pb.dart files:

  • protobuf 6.0.0: Makes PbList and PbMap constructors private (no longer callable as PbList<T>())
  • protoc_plugin 25.0.0: Removes createRepeated() methods from generated code and generates <Type>[] instead

The current generated files (e.g., duration.pb.dart, struct.pb.dart) still contain createRepeated() methods with calls to $pb.PbList<Type>() constructors. This code is incompatible with protobuf 6.0.0's private constructors and will fail at runtime.

Regenerate all .pb.dart files by running the protoc compiler with the updated protoc_plugin 25.0.0.

@codecov
Copy link

codecov bot commented Dec 30, 2025

Codecov Report

❌ Patch coverage is 0% with 472 lines in your changes missing coverage. Please review.
✅ Project coverage is 6.28%. Comparing base (c27e581) to head (9af9b44).

Files with missing lines Patch % Lines
...video/lib/protobuf/video/sfu/models/models.pb.dart 0.00% 363 Missing ⚠️
...o/lib/protobuf/video/sfu/signal_rpc/signal.pb.dart 0.00% 80 Missing ⚠️
.../protobuf/video/sfu/signal_rpc/signal.pbtwirp.dart 0.00% 28 Missing ⚠️
...o/lib/protobuf/video/sfu/models/models.pbenum.dart 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##            main   #1145      +/-   ##
========================================
- Coverage   6.31%   6.28%   -0.03%     
========================================
  Files        595     592       -3     
  Lines      41110   41246     +136     
========================================
- Hits        2595    2594       -1     
- Misses     38515   38652     +137     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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