Skip to content

fix: Use qualified table names in the SQL editor example - #833

Merged
ilyabo merged 1 commit into
mainfrom
fix-ci-examples-build
Aug 4, 2026
Merged

ilyabo merged 1 commit into
mainfrom
fix-ci-examples-build

Conversation

@ilyabo

@ilyabo ilyabo commented Aug 4, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Replace hand-rolled table name objects with makeQualifiedTableName in the SQL editor example
  • Keep autocomplete table schemas aligned with the shared DuckDB API

Testing

Not run (not requested)

Summary by CodeRabbit

  • Bug Fixes
    • Improved SQL editor table-name handling to ensure generated table references are correctly qualified.

@ilyabo ilyabo changed the title Use qualified table names in the SQL editor example fix: Use qualified table names in the SQL editor example Aug 4, 2026
@coderabbitai

coderabbitai Bot commented Aug 4, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

SqlEditor.tsx now imports makeQualifiedTableName and uses it for the users and orders table definitions instead of manually defined table-name objects.

Changes

Qualified table names

Layer / File(s) Summary
Replace manual table names with DuckDB helper
examples/code-editor/src/SqlEditor.tsx
The users and orders table definitions now use makeQualifiedTableName.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly describes the main change: using qualified table names in the SQL editor example.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix-ci-examples-build

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint install failed. For unrecoverable errors, disable the tool in CodeRabbit configuration.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
examples/code-editor/src/SqlEditor.tsx (1)

22-22: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Add a regression test for the helper-backed table metadata.

These calls replace the local toString and toFullString implementations for the users and orders metadata. Add or update a focused test that verifies the canonical and fully qualified names used by autocomplete. Run the example's existing test or type-check command before merge.

As per coding guidelines: add or update tests when changing behavior or public API, when practical. As per PR objective: keep autocomplete table schemas aligned with the shared DuckDB API.

Also applies to: 36-36

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@examples/code-editor/src/SqlEditor.tsx` at line 22, Add a focused regression
test for the autocomplete table metadata created with makeQualifiedTableName,
covering both users and orders and asserting their canonical and fully qualified
names. Reuse the example’s existing test conventions and run its test or
type-check command to verify the shared DuckDB API integration.

Source: Coding guidelines

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@examples/code-editor/src/SqlEditor.tsx`:
- Line 22: Add a focused regression test for the autocomplete table metadata
created with makeQualifiedTableName, covering both users and orders and
asserting their canonical and fully qualified names. Reuse the example’s
existing test conventions and run its test or type-check command to verify the
shared DuckDB API integration.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: cdc0a627-6c8f-46d1-8580-0f819cf67e72

📥 Commits

Reviewing files that changed from the base of the PR and between 3ba2e08 and 103fb0a.

📒 Files selected for processing (1)
  • examples/code-editor/src/SqlEditor.tsx

@ilyabo
ilyabo merged commit 72c4a13 into main Aug 4, 2026
4 of 5 checks passed
@ilyabo
ilyabo deleted the fix-ci-examples-build branch August 4, 2026 22:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant