diff options
| author | salmonik <raisersoft@proton.me> | 2026-05-21 16:37:49 +0200 |
|---|---|---|
| committer | salmonik <raisersoft@proton.me> | 2026-05-21 16:37:49 +0200 |
| commit | 053e3d959c592f5ddc15a0f0898d9b7e1deb8d6f (patch) | |
| tree | 1129d46b5ea3bafcc03b711d0e210515902c14b4 | |
| parent | reqs and test fix (diff) | |
| download | senator-sperma-053e3d959c592f5ddc15a0f0898d9b7e1deb8d6f.tar.gz senator-sperma-053e3d959c592f5ddc15a0f0898d9b7e1deb8d6f.zip | |
requirements shenanigans
Signed-off-by: salmonik <raisersoft@proton.me>
Diffstat (limited to '')
| -rw-r--r-- | AGENTS.md | 2 | ||||
| -rw-r--r-- | README.md | 2 | ||||
| -rw-r--r-- | requirements-dev.txt | 53 | ||||
| -rw-r--r-- | requirements.txt | 47 | ||||
| -rw-r--r-- | scripts/bump_reqs.py | 50 |
5 files changed, 61 insertions, 93 deletions
| @@ -1,7 +1,7 @@ | |||
| 1 | # Agent Instructions for Senator Sperma | 1 | # Agent Instructions for Senator Sperma |
| 2 | 2 | ||
| 3 | ## Required Setup | 3 | ## Required Setup |
| 4 | - Requires **Python 3.13** (3.14 not supported - py-cord incompatibility) | 4 | - Requires **Python 3.14** |
| 5 | - System dependencies: `ffmpeg`, `zbar` library (installed system-wide) | 5 | - System dependencies: `ffmpeg`, `zbar` library (installed system-wide) |
| 6 | - Bot token in `.env` file (copy from `.env.example`) | 6 | - Bot token in `.env` file (copy from `.env.example`) |
| 7 | 7 | ||
| @@ -2,7 +2,7 @@ | |||
| 2 | 2 | ||
| 3 | A Discord bot with music playback, TTS, web search, and utility commands. | 3 | A Discord bot with music playback, TTS, web search, and utility commands. |
| 4 | 4 | ||
| 5 | Requires Python 3.13 (py-cord doesn't support 3.14 yet). | 5 | Requires Python 3.14. |
| 6 | 6 | ||
| 7 | ## Setup | 7 | ## Setup |
| 8 | 8 | ||
diff --git a/requirements-dev.txt b/requirements-dev.txt index 6a6279c..ed5f5cc 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt | |||
| @@ -1,59 +1,18 @@ | |||
| 1 | pytest==8.3.4 | 1 | pytest==9.0.3 |
| 2 | pytest-asyncio==0.25.2 | 2 | pytest-asyncio==1.3.0 |
| 3 | pytest-mock==3.14.0 | 3 | basedpyright==1.39.5 |
| 4 | aiofiles==25.1.0 | 4 | aiofiles==25.1.0 |
| 5 | aiohappyeyeballs==2.6.1 | 5 | aiohttp==3.13.5 |
| 6 | aiohttp==3.13.3 | ||
| 7 | aiosignal==1.4.0 | ||
| 8 | anyio==4.12.1 | ||
| 9 | attrs==25.4.0 | ||
| 10 | basedpyright==1.39.2 | ||
| 11 | beautifulsoup4==4.14.3 | 6 | beautifulsoup4==4.14.3 |
| 12 | brotli==1.2.0 | ||
| 13 | bs4==0.0.2 | ||
| 14 | certifi==2026.2.25 | ||
| 15 | cffi==2.0.0 | ||
| 16 | charset-normalizer==3.4.6 | ||
| 17 | click==8.1.8 | ||
| 18 | contourpy==1.3.3 | ||
| 19 | croniter==6.2.2 | 7 | croniter==6.2.2 |
| 20 | cycler==0.12.1 | ||
| 21 | davey==0.1.4 | ||
| 22 | dotenv==0.9.9 | ||
| 23 | fonttools==4.62.1 | ||
| 24 | frozenlist==1.8.0 | ||
| 25 | gTTS==2.5.4 | 8 | gTTS==2.5.4 |
| 26 | h11==0.16.0 | ||
| 27 | httpcore==1.0.9 | ||
| 28 | httpx==0.28.1 | 9 | httpx==0.28.1 |
| 29 | idna==3.11 | ||
| 30 | kiwisolver==1.5.0 | ||
| 31 | matplotlib==3.10.8 | ||
| 32 | multidict==6.7.1 | ||
| 33 | mutagen==1.47.0 | 10 | mutagen==1.47.0 |
| 34 | nodejs-wheel-binaries==24.14.1 | ||
| 35 | numpy==2.4.4 | ||
| 36 | packaging==26.1 | ||
| 37 | pillow==12.2.0 | 11 | pillow==12.2.0 |
| 38 | propcache==0.4.1 | ||
| 39 | py-cord==2.8.0 | 12 | py-cord==2.8.0 |
| 40 | pycparser==3.0 | ||
| 41 | pycryptodomex==3.23.0 | ||
| 42 | PyNaCl==1.6.2 | ||
| 43 | pyparsing==3.3.2 | ||
| 44 | python-dateutil==2.9.0.post0 | ||
| 45 | python-dotenv==1.2.2 | 13 | python-dotenv==1.2.2 |
| 46 | pytube==15.0.0 | ||
| 47 | pyzbar==0.1.9 | 14 | pyzbar==0.1.9 |
| 48 | qrcode==8.2 | 15 | qrcode==8.2 |
| 49 | RapidFuzz==3.14.3 | 16 | requests==2.34.2 |
| 50 | requests==2.32.5 | ||
| 51 | six==1.17.0 | ||
| 52 | soupsieve==2.8.3 | ||
| 53 | typing_extensions==4.15.0 | ||
| 54 | urllib3==2.6.3 | ||
| 55 | websockets==16.0 | ||
| 56 | yarl==1.23.0 | ||
| 57 | youtube-search-python==1.6.6 | ||
| 58 | yt-dlp==2026.3.17 | 17 | yt-dlp==2026.3.17 |
| 59 | yt-dlp-ejs==0.8.0 | 18 | youtube-search-python==1.6.6 |
diff --git a/requirements.txt b/requirements.txt index d43181f..5fb918e 100644 --- a/requirements.txt +++ b/requirements.txt | |||
| @@ -1,56 +1,15 @@ | |||
| 1 | aiofiles==25.1.0 | 1 | aiofiles==25.1.0 |
| 2 | aiohappyeyeballs==2.6.1 | 2 | aiohttp==3.13.5 |
| 3 | aiohttp==3.13.3 | ||
| 4 | aiosignal==1.4.0 | ||
| 5 | anyio==4.12.1 | ||
| 6 | attrs==25.4.0 | ||
| 7 | basedpyright==1.39.2 | ||
| 8 | beautifulsoup4==4.14.3 | 3 | beautifulsoup4==4.14.3 |
| 9 | brotli==1.2.0 | ||
| 10 | bs4==0.0.2 | ||
| 11 | certifi==2026.2.25 | ||
| 12 | cffi==2.0.0 | ||
| 13 | charset-normalizer==3.4.6 | ||
| 14 | click==8.1.8 | ||
| 15 | contourpy==1.3.3 | ||
| 16 | croniter==6.2.2 | 4 | croniter==6.2.2 |
| 17 | cycler==0.12.1 | ||
| 18 | davey==0.1.4 | ||
| 19 | dotenv==0.9.9 | ||
| 20 | fonttools==4.62.1 | ||
| 21 | frozenlist==1.8.0 | ||
| 22 | gTTS==2.5.4 | 5 | gTTS==2.5.4 |
| 23 | h11==0.16.0 | ||
| 24 | httpcore==1.0.9 | ||
| 25 | httpx==0.28.1 | 6 | httpx==0.28.1 |
| 26 | idna==3.11 | ||
| 27 | kiwisolver==1.5.0 | ||
| 28 | matplotlib==3.10.8 | ||
| 29 | multidict==6.7.1 | ||
| 30 | mutagen==1.47.0 | 7 | mutagen==1.47.0 |
| 31 | nodejs-wheel-binaries==24.14.1 | ||
| 32 | numpy==2.4.4 | ||
| 33 | packaging==26.1 | ||
| 34 | pillow==12.2.0 | 8 | pillow==12.2.0 |
| 35 | propcache==0.4.1 | ||
| 36 | py-cord==2.8.0 | 9 | py-cord==2.8.0 |
| 37 | pycparser==3.0 | ||
| 38 | pycryptodomex==3.23.0 | ||
| 39 | PyNaCl==1.6.2 | ||
| 40 | pyparsing==3.3.2 | ||
| 41 | python-dateutil==2.9.0.post0 | ||
| 42 | python-dotenv==1.2.2 | 10 | python-dotenv==1.2.2 |
| 43 | pytube==15.0.0 | ||
| 44 | pyzbar==0.1.9 | 11 | pyzbar==0.1.9 |
| 45 | qrcode==8.2 | 12 | qrcode==8.2 |
| 46 | RapidFuzz==3.14.3 | 13 | requests==2.34.2 |
| 47 | requests==2.32.5 | ||
| 48 | six==1.17.0 | ||
| 49 | soupsieve==2.8.3 | ||
| 50 | typing_extensions==4.15.0 | ||
| 51 | urllib3==2.6.3 | ||
| 52 | websockets==16.0 | ||
| 53 | yarl==1.23.0 | ||
| 54 | youtube-search-python==1.6.6 | ||
| 55 | yt-dlp==2026.3.17 | 14 | yt-dlp==2026.3.17 |
| 56 | yt-dlp-ejs==0.8.0 | 15 | youtube-search-python==1.6.6 |
diff --git a/scripts/bump_reqs.py b/scripts/bump_reqs.py new file mode 100644 index 0000000..5d253e7 --- /dev/null +++ b/scripts/bump_reqs.py | |||
| @@ -0,0 +1,50 @@ | |||
| 1 | #!/usr/bin/env python3 | ||
| 2 | """Bump all pinned versions in requirements*.txt to latest from PyPI.""" | ||
| 3 | |||
| 4 | import json | ||
| 5 | import re | ||
| 6 | import urllib.request | ||
| 7 | from pathlib import Path | ||
| 8 | |||
| 9 | REQS = sorted(Path().glob("requirements*.txt")) | ||
| 10 | PYPI = "https://pypi.org/pypi/{}/json" | ||
| 11 | |||
| 12 | |||
| 13 | def latest_version(package: str) -> str | None: | ||
| 14 | url = PYPI.format(package) | ||
| 15 | try: | ||
| 16 | with urllib.request.urlopen(url, timeout=10) as resp: | ||
| 17 | data = json.load(resp) | ||
| 18 | return data["info"]["version"] | ||
| 19 | except Exception: | ||
| 20 | return None | ||
| 21 | |||
| 22 | |||
| 23 | def bump_file(path: Path): | ||
| 24 | lines = path.read_text().splitlines() | ||
| 25 | changed = [] | ||
| 26 | for line in lines: | ||
| 27 | m = re.match(r"^([\w-]+(?:\[[\w-]+])?)==[\w.]+$", line) | ||
| 28 | if m: | ||
| 29 | pkg = m.group(1) | ||
| 30 | latest = latest_version(pkg) | ||
| 31 | if latest: | ||
| 32 | changed.append(f"{pkg}=={latest}") | ||
| 33 | if f"{pkg}=={latest}" != line: | ||
| 34 | print(f" {pkg}: {line.split('==')[1]} -> {latest}") | ||
| 35 | else: | ||
| 36 | changed.append(line) | ||
| 37 | print(f" {pkg}: failed to fetch, keeping current") | ||
| 38 | else: | ||
| 39 | changed.append(line) | ||
| 40 | path.write_text("\n".join(changed) + "\n") | ||
| 41 | |||
| 42 | |||
| 43 | def main(): | ||
| 44 | for req in REQS: | ||
| 45 | print(f"\n{req}:") | ||
| 46 | bump_file(req) | ||
| 47 | |||
| 48 | |||
| 49 | if __name__ == "__main__": | ||
| 50 | main() | ||
