Official Telethon's chat! Rules: • Speak English • Stay on topic (questions about Telethon) • Be respectful • Don't ask to ask • Spam-related uses lead to ban • Read https://docs.telethon.dev before asking things here Read more about us @TelethonUpdates
/channel/TelethonChat/657398
/channel/TelethonChat/657369
use
functions.channels.GetAdminedPublicChannelsRequest() or get_dialogs
You should find a different way to link the channel message to it's forward in the group, and then reply in the group directly
Читать полностью…Hello, I am trying to send a message to a channel where I have enabled the discussion/comments feature.
message = await client.send_message(channel, "post")
await client.send_message(channel, 'test comment', comment_to=message.id)
is there is method to ignore the answer just timeout it 1 sec if not answer?
Читать полностью…what alternative for this
try:
client(GetBotCallbackAnswerRequest(
peer=bot_username,
msg_id=msg[0].id,
data=button_id
))
except:
pass
"sendmessagerequest" isn't an error. the part before it is the error, show that
Читать полностью…it could be, In your code more likely, check the "channel" pointing to what you expect that id belong to and the same for id
Читать полностью…edit_admin is "add an admin", there is no other way to promote someone in supergroups, it implicitly does InviteToChannel on server if not joined
Читать полностью…what update we receive as bot when bot got added to channel or group
Читать полностью…it won't. unless you use client.loop.run_until_complete(asyncio.wait_for(...))
and must wrap the click() or client() in actual async def
try:Читать полностью…
await asyncio.wait_for(msg[0].click(data=button_id), timeout=1)
except TimeoutError:
pass
it's as fast as Telegram server and the bot's server, ask them.
if the bot is faulty and doesn't do correct answer(), the method will wait ~15 seconds to expire, you can read about asyncio tasks to run the click in background for this case
you installed it wrong, confirm it was the correct pip for that python, minimum usable is V1.27
Читать полностью…because is not like i try to contact via join request, is like i contact in old way, with ID, so i encounter sendmessagerequest, i need to replicate the new way, that one is permitted with the bot api, and the way is permitted when i click in join request, and after "send message" so i can contact user, and user see in the high "xxxx is and admin of channel you request to join"
Читать полностью…Hi and welcome to the group. Before asking any questions, please read the rules from the group's description, and don't forget to read the docs. Make sure you are using the latest version with pip3 install -U telethon
, since most problems have already been fixed in newer versions.
sometimes get_messages(channel, ids=id) returns None, it's happened 3-4 times, crashing my script and it works after i restart, is it a bug?
Читать полностью…If you're talking about group members, that's the maximum amount server returns
Читать полностью…