all repos — FixYouTube-legacy @ 8e6cea5cba756c2a1d1ca5cdea41395ea4b5acbc

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

fxyoutube/constants.py (view raw)

1MAX_SIZE_MB = 50
2DB_URL = "cache.db"
3UA_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"
4BASE_URL = "https://www.youtube.com/watch?v="
5TS_FORMAT = "%Y-%m-%d %H:%M:%S"
6MAX_SIZE_BYTES = MAX_SIZE_MB * 1_000_000