uv sync
ruff check .
ruff format .
pytestFocused test examples:
pytest tests/test_word_export.py
pytest tests/test_expert_handler_acceptance.py::TestHandleAcceptanceReport::test_handles_contract_not_found- Keep changes small and local when possible
- Update docs when command surface or workflow changes
- Do not commit generated files under
exports/unless explicitly needed - Do not rely on
mezon_ips_bot.egg-info/; packaging output may be stale
When adding or changing bot command flow:
- provide help response for empty invocation path
- update handler help text
- update
docs/commands.mdif command surface changed - add or update tests for help path and main success path
alembic revision --autogenerate -m "message"
alembic upgrade headNotes:
- Alembic scripts live in
app/database/migrations - Alembic URL comes from
.envviaapp_settings.db_uri - Migration metadata target is
RWModel.metadata - Import/export new model modules so autogenerate sees them
- Prefer focused tests around touched handler or service
- App startup logs in to Mezon during lifespan, so tests usually mock Mezon instead of starting full app
- If command help behavior changes, cover empty invocation path explicitly
- add handler in
app/services/bot/handlers/ - decorate top-level command method with
@command(...) - register provider in
app/dependencies/container.py - add provider into
handler_managerlist - add help-path and success-path tests
- settings:
app/core/settings/app.py - bot handlers:
app/services/bot/handlers/ - bot service:
app/services/bot/service.py - repositories:
app/database/repositories/ - tests:
tests/