all repos — FixYouTube-legacy @ 556aabf6284d0dc94693887934a3c04a3353c1ce

A better way to embed YouTube videos everywhere (inspired by FixTweet).

galactic bugfix
Marco Andronaco andronacomarco@gmail.com
Thu, 24 Aug 2023 15:17:26 +0200
commit

556aabf6284d0dc94693887934a3c04a3353c1ce

parent

19a3c98a130934ac200dd7d8e61e2dc80ff0d411

1 files changed, 1 insertions(+), 1 deletions(-)

jump to
M fxyoutube/constants.pyfxyoutube/constants.py

@@ -6,6 +6,6 @@ UA_REGEX = r"bot|facebook|embed|got|firefox\/92|firefox\/38|curl|wget|go-http|yahoo|generator|whatsapp|preview|link|proxy|vkshare|images|analyzer|index|crawl|spider|python|cfnetwork|node"

BASE_URL = "https://www.youtube.com/watch?v=" REPO_URL = "https://github.com/BiRabittoh/FixYouTube" PROXY_HEADERS = { "Content-Type": "video/mp4" } -YTDL_OPTS = { "format": f"best[ext=mp4][filesize<{ MAX_SIZE_MB }M][protocol^=http][protocol!*=dash] / (bv*+ba/b)" } +YTDL_OPTS = { "format": f"best[ext=mp4][filesize<?{ MAX_SIZE_MB }M][filesize_approx<?{ MAX_SIZE_MB }M][protocol^=http][protocol!*=dash] / (bv*+ba/b)" } YTDL_KEYS = [ "id", "title", "description", "uploader", "duration", "height", "width", "url" ] URL_KEY = YTDL_KEYS[-1]