refactor(telegram-bot): add /edit command and make bot.py minimal entrypoint #34

Merged
shoko merged 1 commits from fix/issue-14 into main 2026-04-03 16:36:28 +02:00
Owner

Summary

  • Add cmd_edit as alias for cmd_update
  • Update bot.py to import commands directly instead of via module
  • Register /edit command in bot and post_init commands list
  • Clean up unused imports in bot.py

Changes

bot.py

  • Import commands directly (from commands import cmd_start, cmd_help, ...)
  • Removed unused Update import
  • Added cmd_edit handler
  • Added /edit to post_init command list

commands.py

  • Added cmd_edit = cmd_update alias

Testing

All 119 tests pass.

Fixes #14

## Summary - Add `cmd_edit` as alias for `cmd_update` - Update `bot.py` to import commands directly instead of via module - Register `/edit` command in bot and post_init commands list - Clean up unused imports in bot.py ## Changes ### bot.py - Import commands directly (`from commands import cmd_start, cmd_help, ...`) - Removed unused `Update` import - Added `cmd_edit` handler - Added `/edit` to post_init command list ### commands.py - Added `cmd_edit = cmd_update` alias ## Testing All 119 tests pass. Fixes #14
shoko added 1 commit 2026-04-03 16:27:14 +02:00
- Add cmd_edit as alias for cmd_update
- Update bot.py to import commands directly instead of via module
- Register /edit command in bot and post_init commands list
- Clean up unused imports in bot.py

Fixes #14
han approved these changes 2026-04-03 16:33:18 +02:00
han left a comment
Collaborator

lgtm

lgtm
shoko merged commit 50b09ef721 into main 2026-04-03 16:36:28 +02:00
Sign in to join this conversation.
No Reviewers
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: shoko/jigaido#34