microsoftgraph / microsoftgraph/microsoft-graph-comms-samples

EchoBot: cannot instantiate new AudioVideoFramePlayer with null videoSocket param

Open Beginner friendly
#831 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
No language data
Stars
253
Forks
275
Avg merge
1d 5h
Merged PRs (30d)
1

Description

Describe the issue
The sample code constructs a new AudioVideoFramePlayer but passes null for the videoSocket (second) param. This always causes a null reference exception to be thrown by the AudioVideoFramePlayer constructor as it doesn't allow nulls.

Code Snippet

                this.audioVideoFramePlayerSettings =
                    new AudioVideoFramePlayerSettings(new AudioSettings(20), new VideoSettings(), 1000);
                this.audioVideoFramePlayer = new AudioVideoFramePlayer(
                    (AudioSocket)_audioSocket,
                    null,
                    this.audioVideoFramePlayerSettings);

Expected behavior
Should create a new AudioVideoFramePlayer

Additional context
This is in EchoBot project, BotMediaStream.cs class

https://github.com/microsoftgraph/microsoft-graph-comms-samples/blob/3a4ed77ab35eb29038f9f01d92378c9c175b150f/Samples/PublicSamples/EchoBot/src/EchoBot/Bot/BotMediaStream.cs#L160C1-L166C1

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open Samples/PublicSamples/EchoBot/src/EchoBot/Bot/BotMediaStream.cs around the AudioVideoFramePlayer construction at lines 160-166. Read how AudioVideoFramePlayer is instantiated and verify the constructor requirements for the videoSocket parameter. Done means the EchoBot sample can create the player without the reported null reference exception.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
audio-video-rtc
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.