warp-beacon 2.3.13__tar.gz → 2.3.14__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {warp_beacon-2.3.13/warp_beacon.egg-info → warp_beacon-2.3.14}/PKG-INFO +1 -1
- warp_beacon-2.3.14/warp_beacon/__version__.py +2 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/telegram/utils.py +17 -14
- {warp_beacon-2.3.13 → warp_beacon-2.3.14/warp_beacon.egg-info}/PKG-INFO +1 -1
- warp_beacon-2.3.13/warp_beacon/__version__.py +0 -2
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/LICENSE +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/MANIFEST.in +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/README.md +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/assets/placeholder.gif +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/etc/.gitignore +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/etc/accounts.json +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/etc/proxies.json +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/etc/warp_beacon.conf +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/etc/warp_beacon.service +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/pyproject.toml +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/setup.cfg +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/setup.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/compress/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/compress/video.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/jobs/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/jobs/abstract.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/jobs/download_job.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/jobs/types.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/jobs/upload_job.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/mediainfo/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/mediainfo/abstract.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/mediainfo/audio.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/mediainfo/silencer.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/mediainfo/video.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scheduler/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scheduler/scheduler.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/abstract.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/account_selector.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/exceptions.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/fail_handler.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/instagram/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/instagram/instagram.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/link_resolver.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/youtube/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/youtube/abstract.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/youtube/music.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/youtube/shorts.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/scraper/youtube/youtube.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/storage/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/storage/mongo.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/telegram/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/telegram/bot.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/telegram/handlers.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/telegram/placeholder_message.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/uploader/__init__.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon/warp_beacon.py +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon.egg-info/SOURCES.txt +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon.egg-info/dependency_links.txt +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon.egg-info/entry_points.txt +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon.egg-info/requires.txt +0 -0
- {warp_beacon-2.3.13 → warp_beacon-2.3.14}/warp_beacon.egg-info/top_level.txt +0 -0
@@ -71,19 +71,19 @@ class Utils(object):
|
|
71
71
|
|
72
72
|
@staticmethod
|
73
73
|
def extract_message_author(message: Message) -> str:
|
74
|
-
if message.from_user:
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
if message.sender_chat:
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
return ''
|
74
|
+
#if message.from_user:
|
75
|
+
# if message.from_user.username:
|
76
|
+
# return message.from_user.username
|
77
|
+
# if message.from_user.first_name:
|
78
|
+
# return message.from_user.first_name
|
79
|
+
# if message.from_user.id:
|
80
|
+
return str(message.from_user.mention(style=enums.ParseMode.HTML))
|
81
|
+
#if message.sender_chat:
|
82
|
+
# if message.sender_chat.username:
|
83
|
+
# return message.sender_chat.username
|
84
|
+
# if message.sender_chat.title:
|
85
|
+
# return message.sender_chat.title
|
86
|
+
#return ''
|
87
87
|
|
88
88
|
@staticmethod
|
89
89
|
def compute_leftover(urls: list, message: str) -> str:
|
@@ -107,6 +107,10 @@ class Utils(object):
|
|
107
107
|
@staticmethod
|
108
108
|
async def handle_mentions(chat_id: int, client: Client, message: str) -> str:
|
109
109
|
try:
|
110
|
+
mentions = Utils.mention_re.findall(message)
|
111
|
+
if not mentions:
|
112
|
+
return message
|
113
|
+
|
110
114
|
logging.info("Processing chat_id: '%s'", str(chat_id))
|
111
115
|
chat = await client.get_chat(chat_id)
|
112
116
|
chat_id = chat.id
|
@@ -118,7 +122,6 @@ class Utils(object):
|
|
118
122
|
|
119
123
|
username = ''
|
120
124
|
members = [member async for member in client.get_chat_members(chat_id)]
|
121
|
-
mentions = Utils.mention_re.findall(message)
|
122
125
|
for mention in mentions:
|
123
126
|
username = mention[1:].strip()
|
124
127
|
if username:
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|