AltimateAI / AltimateAI/altimate-code
feat: data_diff audit log
- 主要言語
- TypeScript
- スター
- 811
- フォーク
- 134
- 平均マージ
- 3日 2時間
- マージ済み PR(30日)
- 50
説明
## What does this PR do?
Write a structured append-only audit record on every `data_diff` call so SOC 2 / HIPAA reviewers have forensic evidence of cross-warehouse data comparisons.
## Why
Flagged during the v0.6.0 release review (Chaos Gremlin persona — regulated enterprise perspective). SOC 2 CC7.2 requires "who compared which production tables, with which key columns, when, and what differences were found." Currently `data_diff` returns stats to the caller but nothing durable is persisted; `ctx.ask` captures permission grants but without source/target/key_columns.
## Proposed
- Emit `{ts, user, source, target, source_warehouse, target_warehouse, key_columns, extra_columns, rows_source, rows_target, differences, algorithm}` to a local append-only log file
- Log path: `~/.local/share/altimate-code/audit/data-diff.log` (unix) / equivalent on Windows
- File mode `0600`
- Document rotation policy in the data-parity guide
## Deferred from
v0.6.0 release review. Filed at tag time per no-follow-up-PRs release policy.
## Type of change
- [x] New feature
コントリビューションガイド
評価
この issue はまだ評価されていません。