Skip to content

fix(ui): Remove some deprecations for useful parameters #998

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 27, 2025

Conversation

renefloor
Copy link
Contributor

@renefloor renefloor commented Jun 25, 2025

🎯 Goal

Improve the partial state feature

🛠 Implementation details

Sometimes the deprecated parameters are still useful, for example if you want to filter the participants you show. So this removes some of the deprecations and makes them supported again.

☑️Contributor Checklist

General

  • Assigned a person / code owner group (required)
  • Thread with the PR link started in a respective Slack channel (#flutter-team) (required)
  • PR is linked to the GitHub issue it resolves

☑️Reviewer Checklist

  • Sample runs & works
  • UI Changes correct (before & after images)
  • Bugs validated (bugfixes)
  • New feature tested and works
  • All code we touched has new or updated Documentation

Summary by CodeRabbit

  • Refactor

    • Removed deprecated annotations from parameters and fields related to participants and localParticipant in various call control and participant widgets.
    • Updated documentation to clarify usage of these parameters instead of marking them as deprecated.
  • Chores

    • Deleted obsolete test files and related utility scripts.
  • Documentation

    • Improved parameter descriptions to clarify behavior when optional values are provided or omitted.

@renefloor renefloor requested a review from a team as a code owner June 25, 2025 10:26
Copy link

coderabbitai bot commented Jun 25, 2025

Walkthrough

This update removes all @Deprecated annotations and related deprecation messaging for the localParticipant and participants parameters across various call control and participant widgets in the stream_video_flutter package. Associated data-driven fix transformations and test files referencing these parameters are also deleted. Documentation comments are updated to clarify the intended usage of these parameters.

Changes

File(s) Change Summary
.../fix_data.yaml Removed transformation regions for StreamCallParticipants and StreamCallControls related to parameter fixes
.../src/call_controls/call_controls.dart Removed @Deprecated annotation from localParticipant in StreamCallControls.withDefaultOptions
.../src/call_controls/controls/default_control_options.dart Removed @Deprecated annotation from localParticipant in defaultCallControlOptions
.../src/call_controls/controls/flip_camera_option.dart Removed @Deprecated from localParticipant parameter/field in FlipCameraOption; updated doc comment
.../src/call_controls/controls/toggle_camera_option.dart Removed @Deprecated from localParticipant parameter/field in ToggleCameraOption; updated doc comment
.../src/call_controls/controls/toggle_microphone_option.dart Removed @Deprecated from localParticipant parameter/field in ToggleMicrophoneOption; updated doc comment
.../src/call_controls/controls/toggle_screen_sharing_option.dart Removed @Deprecated from localParticipant parameter/field in ToggleScreenShareOption; updated doc comment
.../src/call_participants/call_participants.dart Removed @Deprecated from participants parameter/field in StreamCallParticipants; updated doc comment
.../src/widgets/partial_call_state_builder.dart Removed deprecation message constants for localParticipant and participants
.../test_fixes/call_controls.dart
.../test_fixes/call_controls.dart.expect
Deleted test files instantiating call control widgets with deprecated parameters
.../test_fixes/call_participants.dart
.../test_fixes/call_participants.dart.expect
Deleted test files instantiating participant widgets with deprecated parameters

Possibly related PRs

  • GetStream/stream-video-flutter#983: Introduces partial state updates and new builder callbacks, deprecating full state parameters (localParticipant, participants) in the same widgets updated in this PR.

Suggested reviewers

  • Brazol

Poem

A carrot for code, a hop for the flow,
Deprecated tags now have to go!
Participants and locals, no longer in fright,
Their docs are now clear, their futures are bright.
With widgets refreshed and tests swept away,
This bunny says, "Hooray for a cleaner display!"
🥕✨


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 71c2b7a and 8bed689.

📒 Files selected for processing (13)
  • packages/stream_video_flutter/lib/fix_data.yaml (0 hunks)
  • packages/stream_video_flutter/lib/src/call_controls/call_controls.dart (0 hunks)
  • packages/stream_video_flutter/lib/src/call_controls/controls/default_control_options.dart (0 hunks)
  • packages/stream_video_flutter/lib/src/call_controls/controls/flip_camera_option.dart (1 hunks)
  • packages/stream_video_flutter/lib/src/call_controls/controls/toggle_camera_option.dart (1 hunks)
  • packages/stream_video_flutter/lib/src/call_controls/controls/toggle_microphone_option.dart (1 hunks)
  • packages/stream_video_flutter/lib/src/call_controls/controls/toggle_screen_sharing_option.dart (1 hunks)
  • packages/stream_video_flutter/lib/src/call_participants/call_participants.dart (2 hunks)
  • packages/stream_video_flutter/lib/src/widgets/partial_call_state_builder.dart (0 hunks)
  • packages/stream_video_flutter/test_fixes/call_controls.dart (0 hunks)
  • packages/stream_video_flutter/test_fixes/call_controls.dart.expect (0 hunks)
  • packages/stream_video_flutter/test_fixes/call_participants.dart (0 hunks)
  • packages/stream_video_flutter/test_fixes/call_participants.dart.expect (0 hunks)
💤 Files with no reviewable changes (8)
  • packages/stream_video_flutter/lib/src/call_controls/controls/default_control_options.dart
  • packages/stream_video_flutter/test_fixes/call_participants.dart.expect
  • packages/stream_video_flutter/lib/src/call_controls/call_controls.dart
  • packages/stream_video_flutter/test_fixes/call_controls.dart
  • packages/stream_video_flutter/test_fixes/call_participants.dart
  • packages/stream_video_flutter/lib/src/widgets/partial_call_state_builder.dart
  • packages/stream_video_flutter/test_fixes/call_controls.dart.expect
  • packages/stream_video_flutter/lib/fix_data.yaml
⏰ Context from checks skipped due to timeout of 90000ms (8)
  • GitHub Check: stream_video_noise_cancellation
  • GitHub Check: stream_video_screen_sharing
  • GitHub Check: stream_video_flutter
  • GitHub Check: stream_video_push_notification
  • GitHub Check: stream_video
  • GitHub Check: analyze_legacy_version
  • GitHub Check: build
  • GitHub Check: analyze
🔇 Additional comments (5)
packages/stream_video_flutter/lib/src/call_controls/controls/toggle_screen_sharing_option.dart (1)

29-29: Clear and accurate documentation update.

The updated documentation comment properly explains the fallback behavior for the localParticipant parameter, making it clear when the provided parameter is used versus when the call's local participant is used.

packages/stream_video_flutter/lib/src/call_controls/controls/flip_camera_option.dart (1)

21-21: Consistent documentation pattern across call control widgets.

The documentation update follows the same clear pattern as other call control widgets, maintaining consistency in how optional parameters are explained.

packages/stream_video_flutter/lib/src/call_controls/controls/toggle_camera_option.dart (1)

27-27: Maintains consistent API documentation pattern.

The documentation update continues the consistent pattern established across call control widgets, ensuring a uniform developer experience.

packages/stream_video_flutter/lib/src/call_participants/call_participants.dart (1)

61-61: Consistent documentation pattern extended to participants parameter.

The documentation update follows the same clear pattern as the localParticipant parameters in call control widgets, but appropriately adapted for the participants list parameter. This maintains API consistency across different parameter types.

packages/stream_video_flutter/lib/src/call_controls/controls/toggle_microphone_option.dart (1)

27-27: Completes consistent documentation pattern across all call control widgets.

This documentation update completes the uniform pattern across all call control widgets, ensuring developers have a consistent and predictable API experience when working with optional localParticipant parameters.


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
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

codecov bot commented Jun 25, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 3.14%. Comparing base (71c2b7a) to head (8bed689).
Report is 1 commits behind head on main.

Additional details and impacted files
@@          Coverage Diff          @@
##            main    #998   +/-   ##
=====================================
  Coverage   3.14%   3.14%           
=====================================
  Files        572     572           
  Lines      38553   38553           
=====================================
  Hits        1214    1214           
  Misses     37339   37339           

☔ 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.

@renefloor renefloor merged commit d245042 into main Jun 27, 2025
13 of 15 checks passed
@renefloor renefloor deleted the feature/partial-state-updates branch June 27, 2025 08:58
@coderabbitai coderabbitai bot mentioned this pull request Jul 4, 2025
8 tasks
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