Summary
When running the official Docker Compose stack (Python 3.11, uvicorn), the backend fails during Telegram bot client startup with an asyncio event-loop error.
Environment
- Official
docker compose setup from this repository
- Python 3.11
- Uvicorn ASGI server
- Failure location:
backend/app/telegram.py around start_one_client (reported ~line 51)
Steps to reproduce
- Clone the repo and start services with the official Docker Compose configuration.
- Start the backend (uvicorn) as defined in the compose file.
- Observe startup logs during Telegram client initialization.
Expected behavior
All configured Telegram bot clients start successfully inside the running application process.
Actual behavior
- Client 0 fails to start during
start_one_client.
- Error indicates a Future attached to a different loop (asyncio event loop mismatch).
Additional notes
- Calling Telegram
getMe separately with asyncio.run(...) works outside the uvicorn/Docker startup path.
- Suggests the Pyrogram/Telegram client asyncio tasks may be bound to a different loop than the one uvicorn uses when the app starts bot clients on startup.
Error context (paraphrased)
Client 0 failed to start
Future attached to a different loop
(at telegram.py → start_one_client)
If maintainers need full stack traces or compose logs from a specific commit, I can attach them on request.
Summary
When running the official Docker Compose stack (Python 3.11, uvicorn), the backend fails during Telegram bot client startup with an asyncio event-loop error.
Environment
docker composesetup from this repositorybackend/app/telegram.pyaroundstart_one_client(reported ~line 51)Steps to reproduce
Expected behavior
All configured Telegram bot clients start successfully inside the running application process.
Actual behavior
start_one_client.Additional notes
getMeseparately withasyncio.run(...)works outside the uvicorn/Docker startup path.Error context (paraphrased)
(at
telegram.py→start_one_client)If maintainers need full stack traces or compose logs from a specific commit, I can attach them on request.