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

Fix flaky test on feature/v1.0.0 #2837

Closed
itsjamie opened this issue Jun 25, 2020 · 7 comments
Closed

Fix flaky test on feature/v1.0.0 #2837

itsjamie opened this issue Jun 25, 2020 · 7 comments
Assignees
Labels
Milestone

Comments

@itsjamie
Copy link
Collaborator

Flaky test on: should seek 5s from end and receive video ended event for Multiple non-alternate audio levels:

Getting video_error_3.

Originally posted by @itsjamie in #2828 (comment)

@robwalch
Copy link
Collaborator

robwalch commented Jun 26, 2020

I saw that too on another PR. I don't see any problems with the stream. And I'm not seeing much in the logs for that failure; It seems like decode error occurs before the seek, but it's unclear. Here's what stands out or could use improvement:

InitPTS for cc: 0 found from video track
What video track? I'm assuming this is what the audio-stream-controller logs when InitPTS comes from the stream-controller. In this scenario there is no video in the main track, but that was a former assumption so I could noticed and fixed these log statements. I see the same output when the stream plays so not sure this is related to the issue.

2020-06-23 04:46:08.415: "[log] > InitPTS for cc: 0 found from video track: 259680480"
2020-06-23 04:46:08.416: "[log] > creating sourceBuffer(audio/mp4;codecs=mp4a.40.5)"
2020-06-23 04:46:08.417: "[log] > main track:audio,container:audio/mp4,codecs[level/parsed]=[mp4a.40.5/mp4a.40.5]"

What was the currentTime at the time of the error? The onerror callback fails the test and looks pretty close to the log where we reachedcurrentTime:0.078,bufferEnd:12.800, but maybe some more details would help:

2020-06-23 04:46:08.551: "[log] > Loading 235776262 of [235776259 ,235776278],level 1, currentTime:0.078,bufferEnd:12.800"
2020-06-23 04:46:08.552: "[log] > main stream-controller: IDLE->FRAG_LOADING"
2020-06-23 04:46:08.564: "[test] > video error, code :3"

The worker logs are completely missing. For example locally I see these messages and it would be helpful to know if something odd happened in the worker.

[log] > manifest codec:mp4a.40.5,ADTS data:type:2,sampleingIndex:6[24000Hz],channelConfig:2
[log] > parsed codec:mp4a.40.5,rate:24000,nb channel:2 

@robwalch robwalch added the CI label Jul 1, 2020
@stale
Copy link

stale bot commented Jul 25, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the Stale label Jul 25, 2020
@robwalch
Copy link
Collaborator

Test runs have been more stable lately. This takes care of the issue mentioned above #2919

@robwalch
Copy link
Collaborator

@itsjamie Im not sure the test is flaky. "Multiple non-alternate audio levels" has two different audio sample rates, which I think present some edge cases when switching levels we don't see often.

We get a media error when appending segments out of order after a level switch and buffer flush. There are also cases where it looks like media is not appended in the correctly location - still looking into how that happens.

@itsjamie
Copy link
Collaborator Author

Good to know that it seems like it's illustrating a race. Thanks for looking into it.

@robwalch
Copy link
Collaborator

robwalch commented Jul 27, 2020

Troubleshooting details can be found here #2921

I merged those improvements for the next release.

We might want to change this ticket or replace it with one that describes the issue with buffering AAC of multiple sample rates.

@robwalch
Copy link
Collaborator

robwalch commented Aug 4, 2020

I'll close this out once the changes from #2943 are merged into feature/v1.0.0 and functional tests are passing (close enough).

robwalch pushed a commit that referenced this issue Aug 4, 2020
* upstream/master:
  Disable flakey smooth switch test on stream with large start gap
  Require min cue duration of 0.25
  Package lock update.
  Minimal Logging on Functional Tests.
  Handle DTS wrapping in initial AVC CTS calculation
  Apply PTSNormalize to ID3 and Text samples to handle timestamp rollover
  Add method to find start pts #2930
  Fix PTS calculation on rollover.
  Bump netlify-cli from 2.58.0 to 2.59.0
  Use ES5 in JavaScript executed by webdriver (for IE11)
  Fix chart fragment rendering issue
  Do not flush audio on audio track switch when both tracks are main variant streams #2837
  Bump @types/mocha from 8.0.0 to 8.0.1
  Bump @babel/plugin-proposal-optional-chaining from 7.10.4 to 7.11.0
  Bump @babel/core from 7.10.5 to 7.11.0
  Improve demo video size menu
  Clear source buffers from chart when new ones are created
  Show multiple demo test tabs using modifier key
  Configure streams for audio and video buffer descrepency in buffer length test
robwalch pushed a commit to jwplayer/hls.js that referenced this issue Aug 6, 2020
* upstream_hls.js/master: (30 commits)
  Handle detach and attach media when calling loadSource with media attached
  Stop loading and reset selected audio track state when reloading a stream
  Add comment describing additional live start gap allowance
  Remove cue duration warning, as this is standard for represending event vs time-ranged based metadata in TextTracks that can be signaled during playback with activeCues change events
  Disable flakey smooth switch test on stream with large start gap
  Require min cue duration of 0.25
  Package lock update.
  Minimal Logging on Functional Tests.
  Handle DTS wrapping in initial AVC CTS calculation
  Apply PTSNormalize to ID3 and Text samples to handle timestamp rollover
  Add method to find start pts video-dev#2930
  Fix PTS calculation on rollover.
  Bump netlify-cli from 2.58.0 to 2.59.0
  Use ES5 in JavaScript executed by webdriver (for IE11)
  Fix chart fragment rendering issue
  Do not flush audio on audio track switch when both tracks are main variant streams video-dev#2837
  Bump @types/mocha from 8.0.0 to 8.0.1
  Bump @babel/plugin-proposal-optional-chaining from 7.10.4 to 7.11.0
  Bump @babel/core from 7.10.5 to 7.11.0
  Improve demo video size menu
@robwalch robwalch added this to the 0.14.8 milestone Aug 7, 2020
@robwalch robwalch closed this as completed Aug 7, 2020
alangdm pushed a commit to alangdm/hls.js that referenced this issue Sep 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Release Planning and Backlog
  
Top priorities
Development

No branches or pull requests

2 participants