-
Notifications
You must be signed in to change notification settings - Fork 3
fix: dbt tool regression — schema format mismatch, silent failures, wrong results #263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
a079c2e
60b5670
2b6f559
c33f4ff
a255220
88dd913
0bf5bed
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -35,21 +35,23 @@ export const AltimateCoreFixTool = Tool.define("altimate_core_fix", { | |
| function formatFix(data: Record<string, any>): string { | ||
| if (data.error) return `Error: ${data.error}` | ||
| const lines: string[] = [] | ||
| if (data.fixed_sql) { | ||
| if (data.fixed_sql && data.fixed !== false) { | ||
| lines.push("Fixed SQL:") | ||
| lines.push(data.fixed_sql) | ||
| if (data.changes?.length) { | ||
| const fixes = data.fixes_applied ?? data.changes ?? [] | ||
| if (fixes.length) { | ||
| lines.push("\nChanges applied:") | ||
| for (const c of data.changes) { | ||
| lines.push(` - ${c.description ?? c}`) | ||
| for (const c of fixes) { | ||
This comment was marked as outdated.
Sorry, something went wrong.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixed in commit |
||
| lines.push(` - ${c.description ?? c.message ?? c}`) | ||
| } | ||
| } | ||
| } else { | ||
| lines.push("Could not auto-fix the SQL.") | ||
| if (data.errors?.length) { | ||
| const unfixable = data.unfixable_errors ?? data.errors ?? [] | ||
| if (unfixable.length) { | ||
| lines.push("\nErrors found:") | ||
| for (const e of data.errors) { | ||
| lines.push(` - ${e.message ?? e}`) | ||
| for (const e of unfixable) { | ||
| lines.push(` - ${e.message ?? e.reason ?? e}`) | ||
| } | ||
| } | ||
| } | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.