Skip to content
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

The latency reported by player statistics is always a fixed number and doesn't change #4474

Closed
duggaraju opened this issue Sep 7, 2022 · 2 comments · Fixed by #5982
Closed
Labels
priority: P2 Smaller impact or easy workaround status: archived Archived and locked; will not be updated type: bug Something isn't working correctly
Milestone

Comments

@duggaraju
Copy link
Contributor

Have you read the FAQ and checked for duplicate open issues?
yes

What version of Shaka Player are you using?

4.2.1
Can you reproduce the issue with our latest release version?
yes

Can you reproduce the issue with the latest code from main?
yes

Are you using the demo app or your own custom app?
both

If custom app, can you reproduce the issue using our demo app?

What browser and OS are you using?
Windows Chrome/Edge

For embedded devices (smart TVs, etc.), what model and firmware version are you using?

What are the manifest and license server URIs?

What configuration are you using? What is the output of player.getConfiguration()?

What did you do?

Play the following stream URL: https://lldemo-usw22.streaming.media.azure.net/612db94f-b556-4c84-b714-fa18d607320c/edaef292-ea7c-4070-af2c-373964170fc3.ism/manifest(format=m3u8-cmaf).m3u8 (you might have to try multiple times due to another bug)

What did you expect to happen?
The player latency reported by player.getStats().liveLatency to reflect the end to end latency.
What actually happened?

The latency returned is a fixed constant number and doesn't reflect the correct latency.

@duggaraju duggaraju added the type: bug Something isn't working correctly label Sep 7, 2022
@github-actions github-actions bot added this to the v4.3 milestone Sep 7, 2022
@duggaraju
Copy link
Contributor Author

The issue is in this code in player.js:
if (this.isLive()) {
const now = this.getPresentationStartTimeAsDate().valueOf() +
this.seekRange().end * 1000;
const latency = (Date.now() - now) / 1000;
this.stats_.setLiveLatency(latency);
}

It is using seekRange().end. Instead it should be video.currentTime to give the correct latency.

@adgllorente
Copy link
Contributor

@joeyparrish we have seen this issue too, is it expected to change?

@avelad avelad modified the milestones: v4.3, v4.4 Nov 11, 2022
@avelad avelad modified the milestones: v4.4, v4.5 Aug 31, 2023
@avelad avelad modified the milestones: v4.5, v4.6 Oct 5, 2023
@avelad avelad modified the milestones: v4.6, v5.0 Nov 16, 2023
@avelad avelad modified the milestones: v4.7, v5.0 Dec 4, 2023
@avelad avelad added the priority: P2 Smaller impact or easy workaround label Dec 4, 2023
avelad added a commit that referenced this issue Dec 5, 2023
avelad added a commit that referenced this issue Dec 5, 2023
avelad added a commit that referenced this issue Dec 5, 2023
@shaka-bot shaka-bot added the status: archived Archived and locked; will not be updated label Feb 3, 2024
@shaka-project shaka-project locked as resolved and limited conversation to collaborators Feb 3, 2024
joeyparrish pushed a commit that referenced this issue Feb 17, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
priority: P2 Smaller impact or easy workaround status: archived Archived and locked; will not be updated type: bug Something isn't working correctly
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants