-
Notifications
You must be signed in to change notification settings - Fork 805
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
Show HLS Playlist for the VideoPress video url, instead of fragmented mp4 file #20839
Conversation
Thank you for your PR! When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:
This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖 The e2e test report can be found here. Please note that it can take a few minutes after the e2e tests checks are complete for the report to be available. Once your PR is ready for review, check one last time that all required checks (other than "Required review") appearing at the bottom of this PR are passing or skipped. Jetpack plugin:
|
@@ -731,7 +731,11 @@ function videopress_get_attachment_url( $post_id ) { | |||
return null; | |||
} | |||
} else { | |||
$return = $meta['videopress']['file_url_base']['https'] . $meta['videopress']['files']['hd']['mp4']; | |||
$return = $meta['videopress']['file_url_base']['https'] . ( | |||
$meta['videopress']['files']['hd']['hls'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we have it pull the hd_1080p
entry if it's available? I think maybe we discussed this on our call but can't remember what decision was made there 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or maybe this is fine for now until we have streaming playlists and can just use those 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thats what I was thinking. I don't want to start hard-coding format lists in Jetpack again, and once adaptive is ready we'll just use that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested well for me.
@@ -731,7 +731,11 @@ function videopress_get_attachment_url( $post_id ) { | |||
return null; | |||
} | |||
} else { | |||
$return = $meta['videopress']['file_url_base']['https'] . $meta['videopress']['files']['hd']['mp4']; | |||
$return = $meta['videopress']['file_url_base']['https'] . ( | |||
$meta['videopress']['files']['hd']['hls'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we check if $meta['videopress']['files']['hd']['hls']
is set before we check for it here, just like we do for $meta['videopress']['files']['hd']['mp4']
above?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, I can change the condition here to be more explicit with an isset()
.
* master: tools: Tool to report unreleased projects (#20874) Add max length for stacktrace in Slack notifications (#20913) Show HLS Playlist for the VideoPress video url, instead of fragmented mp4 file (#20839) VideoPress: Fix VideoPress Attachment Deletions on wp.com (#20832) Update various JS dependencies (#20890) Widget Visibility: add scaffolding for upcoming editor features. (#20910) Heartbeat: Fix typo (#20901) Social Icons: fix being able to remove icons (#20899) Update To-Test.md for Jetpack 10.1 (#20894) Update dependency size-limit to v5 (#20893) Release: start 10.2 cycle (#20896) Jetpack 10.1 Changelog (#20892) E2E tests: add report name option in Slack notification (#20887) Carousel: add more specific selectors for the carousel cursor (#20882) E2E Tests: Fix pre-connection test (#20888) Search: fix body scroll for overlay open/close (#20733) E2E Tests: Fix mailchimp test (#20855) E2E tests: improve error handling (#20884)
This PR exposes the HLS playlist as the video url for all videos that were uploaded and transcoded using the new transcode process (default for all videopress uploads, no options for not transcoding this way). This change is in response to some support requests where 3rd party video players were being used on a site, instead of the VideoPress video player (which isn't a scenario that we directly support, but seems to have been working fine until we started working on the video streaming improvements).
A user's process for configuring the 3rd party player was to copy the video url from the Media Library and provide it to the player. The result of this was the video file was not playing until the entire file was downloaded since it is a fragmented mp4 file (due to the new transcode process). The implication of this change is that the 3rd party player will now need to support HLS playlists in order to play the video.
Fixes 931-gh-Automattic/greenhouse
Changes proposed in this Pull Request:
Jetpack product discussion
Not a Jetpack Product discussion, but a description of the issue and discussion with HEs 928-gh-Automattic/greenhouse
If this seems like something that needs a larger discussion, I'm happy to start a P2 post for it.
Does this pull request change what data or activity we track or use?
nope
Testing instructions:
.master.m3u8
if it was uploaded recently (the last month or so depending on the type of user being tested with).mp4
should be displayed