Skip to content

Conversation

@pierre-lehnen-rc
Copy link
Contributor

@pierre-lehnen-rc pierre-lehnen-rc commented Sep 26, 2025

Proposed changes (including videos or screenshots)

Issue(s)

Steps to test or reproduce

Further comments

Summary by CodeRabbit

  • New Features
    • Added optional debug logging for VoIP media calls. When launched with a debug query parameter in the URL (e.g., ?debug or ?debug-voip), the app emits detailed console logs to aid troubleshooting, while errors and warnings are always shown.
    • Integrated the new logging into media call sessions to provide clearer visibility into call setup and media signaling behavior during diagnostics without affecting normal operation.

@dionisio-bot
Copy link
Contributor

dionisio-bot bot commented Sep 26, 2025

Looks like this PR is ready to merge! 🎉
If you have any trouble, please check the PR guidelines

@changeset-bot
Copy link

changeset-bot bot commented Sep 26, 2025

⚠️ No Changeset found

Latest commit: cc12d0d

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Sep 26, 2025

Walkthrough

Adds a new MediaCallLogger class implementing IMediaSignalLogger for conditional console logging based on URL debug flags, and wires it into MediaSignalingSession by passing a new MediaCallLogger instance during session creation in useMediaSessionInstance.

Changes

Cohort / File(s) Summary of Changes
VOIP logging utility
packages/ui-voip/src/v2/MediaCallLogger.ts
Added new class MediaCallLogger implementing IMediaSignalLogger; reads debug/debug-voip URL params to gate log/debug; warn/error always output.
Media session integration
packages/ui-voip/src/v2/useMediaSessionInstance.ts
Imported MediaCallLogger and passed new MediaCallLogger() as logger option when constructing MediaSignalingSession.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  participant UI as UI/Caller
  participant Store as MediaSessionStore.makeInstance
  participant Session as MediaSignalingSession
  participant Logger as MediaCallLogger
  participant Console as Console

  UI->>Store: create session
  Store->>Logger: new MediaCallLogger()
  Store->>Session: new MediaSignalingSession({ logger: Logger })
  note right of Session: Session uses provided logger

  alt debug flag present (debug|debug-voip)
    Session->>Logger: log/debug(...)
    Logger->>Console: console.log/debug(...)
  else no debug flag
    Session->>Logger: log/debug(...)
    Logger--xConsole: no output
  end

  Session->>Logger: warn/error(...)
  Logger->>Console: console.warn/error(...)
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

I twitch my ears at logs that bloom,
A whisper: “debug” lifts the gloom.
When calls go smooth, I softly thump,
On errors—warn!—I give a jump.
New tracks in snow, a clearer trail—
Quick paws, neat prints, no noisy tale. 🐇📞

Pre-merge checks and finishing touches

✅ 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 clearly and concisely describes the primary change, namely enabling the media calls client logger, which matches the addition of the MediaCallLogger class and its integration into the media session setup.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.
✨ Finishing touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch chore/media-call-client-log

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.

@pierre-lehnen-rc pierre-lehnen-rc added the stat: QA assured Means it has been tested and approved by a company insider label Sep 26, 2025
@pierre-lehnen-rc pierre-lehnen-rc marked this pull request as ready for review September 26, 2025 17:25
@pierre-lehnen-rc pierre-lehnen-rc added this to the 7.11.0 milestone Sep 26, 2025
@dionisio-bot dionisio-bot bot added the stat: ready to merge PR tested and approved waiting for merge label Sep 26, 2025
Copy link
Contributor

@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: CodeRabbit UI

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Jira 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 d204ec6 and 7b979d3.

📒 Files selected for processing (2)
  • packages/ui-voip/src/v2/MediaCallLogger.ts (1 hunks)
  • packages/ui-voip/src/v2/useMediaSessionInstance.ts (2 hunks)
🧰 Additional context used
🧬 Code graph analysis (2)
packages/ui-voip/src/v2/useMediaSessionInstance.ts (1)
packages/ui-voip/src/v2/MediaCallLogger.ts (1)
  • MediaCallLogger (3-26)
packages/ui-voip/src/v2/MediaCallLogger.ts (1)
packages/media-signaling/src/definition/logger.ts (1)
  • IMediaSignalLogger (1-6)
⏰ 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). (3)
  • GitHub Check: 📦 Build Packages
  • GitHub Check: CodeQL-Build
  • GitHub Check: CodeQL-Build
🔇 Additional comments (1)
packages/ui-voip/src/v2/useMediaSessionInstance.ts (1)

8-117: Logger wiring looks good

Passing the new MediaCallLogger into the session ensures the signaling stack can honor the debug flag without touching the rest of the flow. Looks solid.

@codecov
Copy link

codecov bot commented Sep 26, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 67.41%. Comparing base (1efc96b) to head (cc12d0d).
⚠️ Report is 1 commits behind head on develop.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##           develop   #37079      +/-   ##
===========================================
+ Coverage    66.28%   67.41%   +1.12%     
===========================================
  Files         3094     3328     +234     
  Lines       109753   113342    +3589     
  Branches     19721    20561     +840     
===========================================
+ Hits         72753    76410    +3657     
+ Misses       34668    34337     -331     
- Partials      2332     2595     +263     
Flag Coverage Δ
e2e 57.35% <ø> (+4.82%) ⬆️
unit 71.14% <ø> (-0.04%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@kodiakhq kodiakhq bot merged commit b4444e6 into develop Sep 26, 2025
49 checks passed
@kodiakhq kodiakhq bot deleted the chore/media-call-client-log branch September 26, 2025 21:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stat: QA assured Means it has been tested and approved by a company insider stat: ready to merge PR tested and approved waiting for merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants