feat: stabilize category rule operations
approve dcy-001 and add REQ/BAT evidence pass selected DB path through Streamlit rule actions expose delete_category_rule MCP tool add category rule deletion regression
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
# BAT-001 Verification
|
||||
|
||||
## Status
|
||||
- Ready for Release: true
|
||||
- QC Verdict: PASS_WITH_NOTES
|
||||
- Last Updated (KST): 2026-06-26 23:41
|
||||
|
||||
## Acceptance Mapping
|
||||
|
||||
| REQ | AC | Evidence | Result |
|
||||
| --- | --- | --- | --- |
|
||||
| REQ-001 | AC-1 | `dashboard/app.py` diff: `seed_default_category_rules`, `preview_categorization`, `apply_categorization_rules` now receive `db_path=db_path`; Streamlit AppTest preview/apply smoke used `JARCA_LEDGER_DB_PATH=/tmp/jarca-ledger-bat-001-smoke.sqlite3` and default DB mtime stayed unchanged. | Pass |
|
||||
| REQ-001 | AC-2 | `jarca_ledger_mcp/server.py` diff adds `delete_category_rule(rule_id: str)` MCP tool; `hermes mcp test jarca-ledger` discovered 41 tools including `delete_category_rule`. | Pass |
|
||||
| REQ-001 | AC-3 | `pytest tests/test_category_rule_filters.py` includes `test_delete_category_rule_removes_rule_and_reports_missing_ids`; result: 3 passed. | Pass |
|
||||
| REQ-001 | AC-4 | py_compile, targeted pytest, full pytest, and MCP smoke all passed; command outputs summarized below. | Pass |
|
||||
| REQ-001 | AC-5 | Streamlit was run with synthetic fixture DB `/tmp/jarca-ledger-bat-001-smoke.sqlite3`; no original financial file/password/real account fixture used; `/root/.local/share/jarca/ledger.sqlite3` mtime before/after preview/apply smoke remained `1782190349`. | Pass with substitute smoke |
|
||||
|
||||
## Evidence Log
|
||||
- `python -m py_compile jarca_ledger_mcp/*.py dashboard/app.py` → exit 0.
|
||||
- `pytest tests/test_category_rule_filters.py` → `3 passed in 1.77s`.
|
||||
- `pytest tests/test_cross_account_transfer_matching.py` → `3 passed in 1.92s`.
|
||||
- `pytest` → `17 passed, 4 skipped in 17.63s`.
|
||||
- `hermes mcp test jarca-ledger` → connected in 2460ms; 41 tools discovered; `delete_category_rule` listed.
|
||||
- Streamlit server smoke:
|
||||
- port 8501 was occupied, so port 8502 was used.
|
||||
- `curl -I http://127.0.0.1:8502` → `HTTP/1.1 200 OK`.
|
||||
- Browser tool failed before page load because Chromium snap is not installed: `Chrome exited early ... requires the chromium snap to be installed`.
|
||||
- Substitute AppTest smoke output: `exceptions 0`, title `⚙️ 분류 규칙`, subheader `현재 분류 규칙`, buttons `추가`, `변경`, `삭제`, `기본 규칙 seed/update`, `규칙 preview`, `규칙 적용`, synthetic rule text `스모크상점` present.
|
||||
- AppTest preview/apply output: `preview_exceptions 0`, info `스캔 0건 · 매칭 0건 · 미분류 0건`, `apply_exceptions 0`, success `0건 적용`, default DB mtime unchanged.
|
||||
|
||||
## Blocking Issues
|
||||
- 없음.
|
||||
|
||||
## QC Gate
|
||||
- Reviewer profile: `jarcaledgerqc` (검수관)
|
||||
- Command: `jarcaledgerqc chat -q "QC gate 요청..."`
|
||||
- Verdict: `PASS_WITH_NOTES`
|
||||
- Blockers: 없음
|
||||
- Notes:
|
||||
- Browser-level screenshot evidence was unavailable because Chromium snap is not installed; AppTest + HTTP 200 was accepted as substitute evidence for this small BAT.
|
||||
- Future Streamlit UX/E2E batches should restore real browser/screenshot evidence.
|
||||
- Optional future strengthening: temp MCP subprocess create/delete/list actual tool-call E2E.
|
||||
|
||||
## Notes
|
||||
- No destructive migration.
|
||||
- No direct mutation of the original 운영 DB during smoke; only mtime check was performed on default DB.
|
||||
- Browser screenshot evidence was attempted but blocked by missing Chromium; AppTest + HTTP 200 evidence is the recorded semi-automated substitute.
|
||||
Reference in New Issue
Block a user