fix: coerce empty-string dialect to no-hint across native handlers (unknown dialect '' throw)
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 72/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 静か
- 技術スタック
- typescript
調査の方向性
packages/opencode/src/altimate/native/altimate-core.ts と packages/opencode/src/altimate/native/sql/register.ts に列挙されているハンドラーを調査し、sql/register.ts:433-434 にある既存の規約から始めます。名前が示されている各 dialect 転送箇所を確認し、空文字列の dialect が dialect ヒントとして altimate-core に到達しなくなっていること、また有効な dialect 値が変更されずに維持されていることを検証します。
索引モデルが issue の本文から書いたものです。
説明
Description
Pre-existing latent bug surfaced while wiring core 0.5.1 (#925 follow-up). altimate-core throws unknown dialect '' on an empty-string dialect. Several native handlers forward params.dialect ?? undefined, so a literal "" is passed through (empty string is not nullish) and the engine throws:
packages/opencode/src/altimate/native/altimate-core.ts:Schema.fromDdl(migration),columnLineage,formatSql,extractMetadata,compareQueries,importDdlpackages/opencode/src/altimate/native/sql/register.ts:columnLineage
In the dbt review pipeline these are protected today because review/run.ts resolves config.dialect (auto-detect → fallback "snowflake") before runReview. But any direct caller using the documented default (ReviewConfig.dialect = "") would hit the throw → caught → silent degradation (e.g., column-breakage/PII-via-lineage lanes return empty).
Fix
Normalize these sites to params.dialect || undefined (coerce ""/null/undefined → undefined), matching the convention already used in sql/register.ts:433-434 and the checkEquivalence sites hardened in the parent PR. No valid dialect is falsy, so the change is behavior-neutral except for eliminating the "" throw.
Context
Independently flagged by a consensus code-review model (Gemini) during the parent PR. Kept out of the parent PR for scope discipline (those sites are not 0.5.1 functionality).
- 主要言語
- TypeScript
- スター
- 813
- フォーク
- 134
- 平均マージ
- 2日 2時間
- マージ済み PR(30日)
- 67
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
AltimateAI/altimate-code のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
AltimateAI/altimate-code#1359 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
AltimateAI/altimate-code#1323 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 86/100
AltimateAI/altimate-code#1288 ·
-
難易度 1/5 1時間未満 初心者へのやさしさ 92/100
AltimateAI/altimate-code#1285 ·
-
privacy: Altimate Base consent dialog no longer discloses persistent per-installation identifier オープン
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
AltimateAI/altimate-code#1284 ·
AltimateAI/altimate-code の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
bcgov/bc-wallet-mobile#4761 · コメント 1 件 ·
-
external-issue to-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
-
area-deployment area-integrations triage:bot-seen
難易度 2/5 半日 初心者へのやさしさ 86/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
-
refactor
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100