Fix CI deps, MSK tax hour, portable /status uptime, configurable admin token path
checks / pytest (push) Has been cancelled
checks / moderation (push) Has been cancelled
checks / node (push) Has been cancelled

- requirements-dev: add pytest-asyncio (async tests were failing in CI)
- nightly tax: compute MSK hour explicitly instead of host-local time
- /status: uptime via psutil instead of shell 'uptime'
- IISHKO_ADMIN_TOKEN_FILE overrides the admin token path
- Mini App: API base derived from location.origin
- dedupe repeated ticket tags; bounded dependency versions

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-31 02:38:30 +03:00
co-authored by Claude Opus 5.5
parent a05a36aa7b
commit 07405e68f4
5 changed files with 32 additions and 28 deletions
+6 -6
View File
@@ -198,11 +198,11 @@ async def gate_check(api_key):
# A single write transaction serializes main/pm/sol/additional request counters.
RL_TOTAL = {0: 5000, 1: 5000, 2: 10000, 3: 20000, 4: 30000}
RL_PREM = {
"gpt-6-luna": {0: 200, 1: 500, 2: 1500, 3: 5000, 4: 10000}, # [LIMIT-BOOST2 2510] # [LIMIT-BOOST2 2510] # [LIMIT-BOOST2 2510] # [LUNA-BOOST 2510] daily request caps per rank
"gpt-6.1-sol": {0: 100, 1: 250, 2: 800, 3: 2000, 4: 5000}, # [LIMIT-BOOST2 2510] # [LIMIT-BOOST2 2510] # [LIMIT-BOOST2 2510]
"opus": {0: 100, 1: 250, 2: 800, 3: 2000, 4: 5000}, # [LIMIT-BOOST2 2510] # [LIMIT-BOOST2 2510] # [LIMIT-BOOST2 2510]
"fable": {0: 100, 1: 250, 2: 800, 3: 2000, 4: 5000}, # [LIMIT-BOOST2 2510] # [LIMIT-BOOST2 2510] # [LIMIT-BOOST2 2510]
"astra": {0: 100, 1: 250, 2: 800, 3: 2000, 4: 5000}, # [LIMIT-BOOST2 2510] # [LIMIT-BOOST2 2510] # [LIMIT-BOOST2 2510]
"gpt-6-luna": {0: 200, 1: 500, 2: 1500, 3: 5000, 4: 10000}, # [LIMIT-BOOST2 2510] # [LUNA-BOOST 2510] daily request caps per rank
"gpt-6.1-sol": {0: 100, 1: 250, 2: 800, 3: 2000, 4: 5000}, # [LIMIT-BOOST2 2510]
"opus": {0: 100, 1: 250, 2: 800, 3: 2000, 4: 5000}, # [LIMIT-BOOST2 2510]
"fable": {0: 100, 1: 250, 2: 800, 3: 2000, 4: 5000}, # [LIMIT-BOOST2 2510]
"astra": {0: 100, 1: 250, 2: 800, 3: 2000, 4: 5000}, # [LIMIT-BOOST2 2510]
}
RL_NAMES = {0: "Новичок", 1: "Новичок", 2: "Актив", 3: "Профи", 4: "Легенда"}
@@ -1080,7 +1080,7 @@ async def brand_asset(req):
# Provision: new-api user "tg<id>" via admin API, password kept in skin-local store (0600).
# Login: server-side POST /api/user/login, Set-Cookie forwarded to the browser.
TG_BOT_CONFIG = bot_config_path()
TG_ADMIN_TOKEN_FILE = "/root/.secrets/newapi_admin_token"
TG_ADMIN_TOKEN_FILE = os.environ.get("IISHKO_ADMIN_TOKEN_FILE", "/root/.secrets/newapi_admin_token")
TG_PROVISION_DB = skin_db_path()
TG_AUTH_MAX_AGE = 900
TG_SID_SECRET_FILE = os.environ.get("TG_SID_SECRET_FILE", "/root/.secrets/iishko_tg_sid_secret")