[MBL-19606][All] Enable DASH playback#3663
Open
kristofnemere wants to merge 1 commit intomasterfrom
Open
Conversation
- Add shouldOpenMediaInternally helper in pandautils that detects audio/video by mimeClass, mimeType, or URL extension (including /cmaf) - Route audio/video inbox attachments through BaseViewMediaActivity in Student, Teacher, and Parent (Parent previously only downloaded) - ExoAgent: detect /cmaf single-use URLs up front and use DASH, fall back to DASH retry on UnrecognizedInputFormatException for media_download URLs - Student/Teacher openMedia and BaseRouterActivity.openMedia accept mimeType/mimeClass so detection happens inside, not at the call sites - Add unit tests for shouldOpenMediaInternally Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Contributor
🧪 Unit Test Results✅ 📱 Parent App
✅ 📱 Student App
✅ 📱 Teacher App
✅ 🌅 Horizon
✅ 📦 Submodules
📊 Summary
Last updated: Thu, 23 Apr 2026 14:10:31 GMT |
Contributor
📊 Code Coverage Report
|
Contributor
Contributor
Contributor
adamNagy56
requested changes
Apr 27, 2026
Contributor
There was a problem hiding this comment.
- In the Parent app, if I start a video (for example in the Inbox) and then rotate the screen, the video stops and has to be restarted. However, this is already handled in the Student and Teacher apps, where playback continues after rotation, so it would be great to achieve the same behavior here as well for consistency. (See attached video.)
The other findings are not specially related to this PR so i will create separate tickets for those as we discussed in Slack.
3879.mp4
tamaskozmer
approved these changes
Apr 28, 2026
|
|
||
| override fun routeToMediaAttachment(mediaComment: MediaComment) { | ||
| fileDownloader.downloadFileToDevice(mediaComment.url, mediaComment.displayName, mediaComment.contentType) | ||
| val url = mediaComment.url ?: return |
Contributor
There was a problem hiding this comment.
We skip error handling in this case, since it is handled in the downloadFileToDevice.
| /** The current URI being used (may be modified for DASH retry) */ | ||
| private var currentUri: Uri = uri | ||
| /** The current PlayerView, kept so the retry can re-attach after recreating the player */ | ||
| private var mPlayerView: PlayerView? = null |
Contributor
There was a problem hiding this comment.
We should not use hungarian notation.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Test plan:
Main use cases
Test each of the following on both a regular non-stream-enabled sandbox and a stream-enabled sandbox — media URLs differ between the two (direct files vs. Kaltura CMAF/DASH streams), and both paths need to keep working.
Verify on both sandboxes:
Affected screens (please exercise all of them in addition to the main use cases)
Student
Teacher
Parent (new behavior — previously audio/video attachments always downloaded)
Additional checks
refs: MBL-19606
affects: Student, Teacher, Parent
release note: Enabled DASH/CMAF playback for audio and video in inbox messages, submission comments, media-recording submissions, and media embedded in pages/quizzes/syllabus. Parent inbox now plays audio and video in-app instead of only downloading.
Checklist