diff --git a/pyproject.toml b/pyproject.toml index 53d4890..caeee29 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -10,46 +10,17 @@ authors = [ ] description = "Very simple async matrix bot library" readme = "README.md" -requires-python = ">=3.12" +requires-python = ">=3.13" classifiers = [ "Programming Language :: Python :: 3", "Operating System :: OS Independent", ] dependencies = [ - "aioconsole==0.8.2", - "aiofiles==25.1.0", - "aiohappyeyeballs==2.7.1", - "aiohttp==3.14.3", - "aiohttp_socks==0.12.0", - "aiosignal==1.4.0", + "matrix-nio[e2e]==0.26.0", "aiosqlite==0.22.1", - "atomicwrites==1.4.1", - "attrs==26.1.0", - "build==1.5.0", - "cachetools==7.1.7", - "frozenlist==1.8.0", - "h11==0.16.0", - "h2==4.4.1", - "hpack==4.2.0", - "hyperframe==6.1.0", - "idna==3.19", - "jsonschema==4.26.0", - "jsonschema-specifications==2025.9.1", - "matrix-nio==0.26.0", - "multidict==6.7.1", - "packaging==26.3", - "peewee==3.19.0", - "propcache==0.5.2", - "pycryptodome==3.23.0", - "pyproject_hooks==1.2.0", - "python-socks==3.0.0", - "referencing==0.37.0", - "rpds-py==2026.6.3", - "unpaddedbase64==2.1.0", - "vodozemac==0.10.0", - "yarl==1.24.5", "python-magic==0.4.27", - "pillow==12.3.0" + "pillow==12.3.0", + "pydantic==2.14.4" ] [project.urls] diff --git a/src/mab/bot/_client_auth.py b/src/mab/bot/_client_auth.py index b942607..a3be751 100644 --- a/src/mab/bot/_client_auth.py +++ b/src/mab/bot/_client_auth.py @@ -1,5 +1,4 @@ import asyncio -import aioconsole import logging import os from ._database import _Database @@ -20,10 +19,8 @@ class ClientAuth: async def _default_password_callback(self) -> str: if self._config is None: raise RuntimeError("No config") - if "MATRIX_PASSWORD" in os.environ: - return os.environ["MATRIX_PASSWORD"] - if self._config.allow_ainput_password: - return await aioconsole.ainput("Matrix password: ") + if "MAB_PASSWORD" in os.environ: + return os.environ["MAB_PASSWORD"] raise RuntimeError("Can't get password") async def _login_using_session_data(self, client: AsyncClient) -> None: diff --git a/src/mab/types.py b/src/mab/types.py index a5d0adb..19dbe6f 100644 --- a/src/mab/types.py +++ b/src/mab/types.py @@ -31,9 +31,6 @@ class MatrixBotConfig: auto_ffmpeg: bool = True """Enabled automatic `ffmpeg` execution to generate some media (e.g. thumbnails)""" - allow_ainput_password: bool = True - """Allow `aioconsole.ainput` usage to get user password""" - client_sync_period_ms: int = 5000 """Sync period for `nio.AsyncClient` in milliseconds"""