Support full 2GB/2h video downloads via Local Bot API, clean VK wiki links and remove fallback links
This commit is contained in:
+1
-9
@@ -371,16 +371,8 @@ class TelegramPoster:
|
||||
3. Tries sendRichMessage first.
|
||||
4. If unavailable, falls back to legacy media groups / single media / text.
|
||||
"""
|
||||
# Append link-only media notice if any videos/photos couldn't be downloaded
|
||||
link_only = [m for m in media_items if m.is_link_only]
|
||||
link_text = ""
|
||||
if link_only:
|
||||
lines = [f"- {m.media_type}: <a href=\"{m.original_url}\">ссылка</a>" for m in link_only]
|
||||
link_text = "\n\n<i>Медиа по ссылке:</i>\n" + "\n".join(lines)
|
||||
|
||||
full_raw = (raw_text + link_text).strip()
|
||||
formatted_text = format_post_text(
|
||||
full_raw,
|
||||
raw_text,
|
||||
parse_mode="html",
|
||||
bold_first_line=settings.format_first_line_bold,
|
||||
vk_url=vk_url,
|
||||
|
||||
Reference in New Issue
Block a user