v0.4.0 — Reliable launches, safer files and complete docs
OpenCodeBot 0.4.0 makes topic launches, stopped work and file delivery more predictable, and gives users and operators complete matching English/Russian documentation.
- Launches keep what the card showed. The first prompt and unfinished setup retries use the saved model/reasoning snapshot. Concurrent first prompts share one session creation. Password-protected backend HTTP and SSE now use the correct
opencodeBasic Auth username, with a configurable custom name. - Stopping a topic stops its buffered input. Kill/reset, closure and conversion to FILES/AUDIO discard the whole topic's multipart/attachment buffers. Notification shortcuts change only their caller's preference. Recent-topic checks preserve newer names instead of reapplying stale titles.
- Files preserve existing data. Incoming uploads refuse collisions and report earlier successful files after a partial failure. Filename limits count UTF-8 bytes, and long escaped captions retain valid HTML. Photo-to-document retry happens only after a definite photo rejection, avoiding a second send after an uncertain transport error.
- Work stays bounded. Prompt/transcription queues and concurrent gateway deliveries have explicit limits. JSON metadata accepts 64 KiB; files keep streaming. Waiting attachments keep paths instead of base64 copies in memory, enforce the remaining download budget and clean staging after dispatch. Abandoned owned spools are cleaned hourly.
- Long histories cost less. Delivery IDs use per-session Set indexes, no-op updates skip state rewrites, and restart recovery discards torn marker-journal tails while rejecting complete corruption. Disabled binding history prevents old stopped topics from returning after the discovery cache expires.
- Clearer setup and maintenance. POSIX setup records the owner's UID/GID. Native startup includes dependency installation. The Windows deployment wrapper calls npm's JavaScript entrypoint directly. The optional WireGuard helper saves client credentials before installation and avoids a duplicate restart.
- Documentation follows the product. README includes bilingual renderer previews. Language directories share installation, usage, configuration, operations and development categories, with a separate architecture page and language index. One CI job checks syntax, documentation links/examples, existing contracts and isolated smoke.
Validation: 29 existing tests and the extended central smoke passed; GitHub CI passed on Node 22. Real Telegram checks confirmed title-preserving topic probes, deletion detection and long-caption parsing. Local and real POSIX SSH transfers preserved bytes and refused overwrite. UI previews and representative pages of the unchanged eight-page PDF guides were visually inspected. Production passed live health, matched the committed runtime files, and retained pre-rollout profiles and session bindings. Native Windows/Windows SSH execution was not tested on a live host.
Update with git pull --ff-only then npm run deploy:bot. This range changes the host update runner, so Telegram correctly requires manual deployment. Installed artifact plugin/skill copies are unchanged. Back up stopped state and journals before updating; memory-only queues retain their documented restart limits.
Версия 0.4.0 исправляет запуск тем, остановку отложенного ввода и доставку файлов. Документация на русском и английском теперь описывает одинаковые возможности и ограничения.
- Сохраняются показанные модель/reasoning; параллельные первые промпты не создают две сессии. Исправлена авторизация HTTP/SSE на серверах с паролем.
- Kill/reset и перевод темы в служебную очищают её буферы целиком. Команды уведомлений персональные. Проверка «Недавних» больше не откатывает переименование.
- FILES не перезаписывает существующий файл. Исправлены длинные кириллические имена, HTML-подписи и повторная отправка после неоднозначной ошибки сети.
- Очереди и шлюз ограничены; ожидающие вложения не хранят base64 в памяти. Проверка маркеров истории ускорена, лишние записи состояния убраны, оборванный хвост журнала восстанавливается.
- Обновлены установщик, запуск npm на Windows, вспомогательный WireGuard-процесс и двуязычная документация. Добавлены наглядные README-превью, описание архитектуры и одна задача CI.
Проверки кода, документации, 29 существующих тестов, smoke и CI прошли. Реальные Telegram/POSIX SSH-сценарии подтверждены; Windows и Windows SSH на живом хосте не проверялись. Рабочий бот обновлён с сохранением профилей и привязок.