That's not really a good reason to change the versioning process based on what you think looks good or not
Читать полностью…Wiki of python-telegram-bot - Category FAQ
My bot doesn't receive messages from groups. Why?
Hi, I’m trying to get the tutorial in https://docs.python-telegram-bot.org/en/v21.0.1/examples.echobot.html to work and I copy-pasted the code. The /start and /help commands both work, but if I send a non-command text the echo
function doesn’t trigger. Adding a logging statement where the update_queue is consumed at https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/_application.py#L1179, I can see that any arbitrary command I send is picked up (not just /start and /help) but non-commands don’t show up at all. Any idea what might be the issue?
telegram.ext.ApplicationBuilder.arbitrary_callback_data
Parameter arbitrary_callback_data of telegram.ext.ExtBot
Parameter maxsize of telegram.ext.CallbackDataCache
arbitrarycallbackdatabot.py
i am trying to upload file with bot.send_document
but i keep running into exceptions. i have tried everything i could think of . the error is The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/codespace/.local/share/virtualenvs/simpletap-WA04qNPT/lib/python3.10/site-packages/telegram/request/_httpxrequest.py", line 276, in do_request
res = await self._client.request(
File "/home/codespace/.local/share/virtualenvs/simpletap-WA04qNPT/lib/python3.10/site-packages/httpx/_client.py", line 1574, in request
return await self.send(request, auth=auth, follow_redirects=follow_redirects)
File "/home/codespace/.local/share/virtualenvs/simpletap-WA04qNPT/lib/python3.10/site-packages/httpx/_client.py", line 1661, in send
response = await self._send_handling_auth(
File "/home/codespace/.local/share/virtualenvs/simpletap-WA04qNPT/lib/python3.10/site-packages/httpx/_client.py", line 1689, in _send_handling_auth
response = await self._send_handling_redirects(
File "/home/codespace/.local/share/virtualenvs/simpletap-WA04qNPT/lib/python3.10/site-packages/httpx/_client.py", line 1726, in _send_handling_redirects
response = await self._send_single_request(request)
File "/home/codespace/.local/share/virtualenvs/simpletap-WA04qNPT/lib/python3.10/site-packages/httpx/_client.py", line 1763, in _send_single_request
response = await transport.handle_async_request(request)
File "/home/codespace/.local/share/virtualenvs/simpletap-WA04qNPT/lib/python3.10/site-packages/httpx/_transports/default.py", line 372, in handle_async_request
with map_httpcore_exceptions():
File "/usr/local/python/3.10.13/lib/python3.10/contextlib.py", line 153, in __exit__
self.gen.throw(typ, value, traceback)
File "/home/codespace/.local/share/virtualenvs/simpletap-WA04qNPT/lib/python3.10/site-packages/httpx/_transports/default.py", line 86, in map_httpcore_exceptions
raise mapped_exc(message) from exc
httpx.ReadTimeout
Hmmm, feels like a bug in the library to me, this should be handled properly. Mind creating a mwe and I can debug further later
Читать полностью…Hi, I want to trigger a command every day at a specific time
but I don't understand how
I read the https://docs.python-telegram-bot.org/en/stable/examples.timerbot.html timerbot example
but I don't understand how to check if time has passed
My Guess is that you have app.run_polling() they is bpocking on main and After that you have and updater.run_polling() forgotten somewhere
Читать полностью…What is the version looks like wired???
v21.0.1/
why not simpley 21.1,21.2 like this
commands both work, but if I send a non-command text the echo function doesn’t trigger You can find an explanation of @roolsbot's functionality on 'GitHub.
Читать полностью…this question does not have a general answer. much relies on how you use the concurrency features of PTB. but glad to hear that you solved your problem :)
Читать полностью…Yes. See the docs of +AppBuilder.arbitray_callback_data+, +ExtBot.param.arbitrary_callback_data+, +CDC.param.maxsize+ and also the wiki page on +arbitray callback_data+. !search
Читать полностью…in most of places in ptb docs, they specify like
if block = False then you can't rely on building custom context.
with that
there are
arbitary calbacks
concurrent updates
non blocking handlers
custom context
groups of handler
so , not all features can be used together, it's hard to find which combos break, that's why I asked like that.
Hey. In order for someone to be able to help you, you must ask a good technical question. Please read this short article and try again ;)
Читать полностью…you're in this gorup long enough to know this: Please post code or tracebacks using a pastebin rather than via plain text or a picture. https://pastebin.com/ is quite popular, but there are many alternatives out there. Of course, for very short snippets, text is fine. Please at least format it as monospace in that case.
Читать полностью…Hey. Please provide a minimal working example (MWE). Have a look at Minimal Working Example (MWE) if you need help.
Читать полностью…ext.JobQueue.run_daily
python-telegram-bot documentation for this method:
telegram.ext.JobQueue.run_daily