Skip to content

fix(telegram): restore /start menu and UX copy - #26

Merged
scottishwidow merged 1 commit into
mainfrom
fix/telegram-source-skip-start-menu
Apr 25, 2026
Merged

fix(telegram): restore /start menu and UX copy#26
scottishwidow merged 1 commit into
mainfrom
fix/telegram-source-skip-start-menu

Conversation

@scottishwidow

Copy link
Copy Markdown
Owner

Summary

  • rename detailed song source label to Джерело (оригінал)
  • restore Пропустити button for optional chart key input (keep Скасувати)
  • publish /start command on startup and set Telegram chat menu button to Commands
  • add implementation note in docs/features/

Changes

  • src/handlers/repertoire.py: update format_song source label copy
  • src/handlers/charts.py: use skip_cancel_markup for chart-key prompt
  • src/bot/application.py: replace command deletion with:
    • set_my_commands([BotCommand("start", "Відкрити головне меню")])
    • set_chat_menu_button(MenuButtonCommands())
  • tests updated in:
    • tests/test_handlers.py
    • tests/test_application.py
  • docs updated:
    • docs/features/start-command-recovery-and-copy-fixes.md
    • docs/features/README.md

Validation

  • UV_CACHE_DIR=.uv-cache uv run pytest tests/test_handlers.py tests/test_application.py ✅ (50 passed)
  • UV_CACHE_DIR=.uv-cache uv run ruff check .
  • UV_CACHE_DIR=.uv-cache uv run ruff format --check .
  • UV_CACHE_DIR=.uv-cache uv run mypy
  • UV_CACHE_DIR=.uv-cache uv run pytest ⚠️ hangs in this environment at tests/test_repertoire_backup_service.py::test_export_backup_contains_manifest_and_chart_files (timed out while isolating)

Notes

Telegram does not provide a reliable API to re-show the large first-run "Start" prompt for users who cleared history; exposing /start in Commands menu is the practical recovery path.

Update song source label, restore skip button on optional chart key step, and publish /start with Telegram Commands menu button. Add docs and tests for startup and handler behavior.

@scottishwidow scottishwidow left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Self-review completed.

No blocking findings found in the PR diff. The handler changes are narrowly scoped, use existing reply-keyboard helpers, and the startup change uses set_my_commands plus MenuButtonCommands from the installed python-telegram-bot API.

Residual caveat: targeted tests, ruff, format check, and mypy passed locally. Full pytest did not complete in this environment because it hangs at tests/test_repertoire_backup_service.py::test_export_backup_contains_manifest_and_chart_files, which appears unrelated to this PR's touched files.

@scottishwidow
scottishwidow merged commit 49be94e into main Apr 25, 2026
4 checks passed
@scottishwidow
scottishwidow deleted the fix/telegram-source-skip-start-menu branch April 25, 2026 10:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant