AltimateAI / AltimateAI/altimate-code

refactor: split data-diff.ts (1118 lines) into focused modules

オープン
#732 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
TypeScript
スター
811
フォーク
134
平均マージ
3日 2時間
マージ済み PR(30日)
50

説明

## What does this PR do?
Split `packages/opencode/src/altimate/native/connections/data-diff.ts` into multiple files:
- `dialect.ts` — warehouseTypeToDialect, resolveDialect, dateTruncExpr, quoteIdentForDialect
- `cte.ts` — CTE injection and query building
- `partitioning.ts` — buildPartitionDiscoverySQL, buildPartitionWhereClause, runPartitionedDiff
- `orchestrator.ts` — the main runDataDiff entry point

## Why
Flagged during the v0.6.0 release review (Tech Lead persona). The current file is 1,118 lines with 3 `as any` casts and mixes dialect mapping, CTE injection, executor, orchestrator, and partitioning concerns. Violates single-responsibility; makes targeted reviews hard.

## Proposed
Pure refactor — no behavior change. Move functions, preserve imports, update tests.

## Deferred from
v0.6.0 release review. Filed at tag time per no-follow-up-PRs release policy.

## Type of change
- [x] Refactor

コントリビューションガイド

コントリビューションガイドを開く

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。