UI improvements, bug fix -- seed run on duckdb#36
Conversation
|
| Filename | Overview |
|---|---|
| backend/visitran/adapters/duckdb/seed.py | Adds null guard on db_connection and try/except around insert_csv_records to surface a descriptive SeedFailureException instead of a raw AttributeError |
| frontend/src/base/components/environment/NewEnv.jsx | Removes dead custom-data state, fetchProjectByConnection call, projListDep, and EnvCustomDataSection render — clean-up with no functional regressions |
| frontend/src/ide/editor/no-code-model/no-code-model.jsx | Replaces raw span elements in column renderer with CopyableCell, passing formattedValue as both value prop and children so displayed and copied text are consistent |
| frontend/src/service/notification-service.js | Fixes empty notification title for markdown-typed errors by setting finalMessage to 'Failed' instead of an empty string |
| frontend/src/widgets/copyable-cell/copyable-cell.css | New CSS for CopyableCell widget: text-overflow ellipsis for cell text, flex layout for tooltip content, and word-break/pre-wrap for long values |
| frontend/src/widgets/copyable-cell/index.js | New memoized CopyableCell widget with Ant Design Tooltip, clipboard copy on icon click or cell double-click, 2-second checkmark state, and proper timeout cleanup on unmount |
Sequence Diagram
sequenceDiagram
participant U as User
participant T as CopyableCell
participant C as Clipboard API
U->>T: Hover over table cell
T-->>U: Show Tooltip with value + copy icon
U->>T: Click copy icon (or double-click cell text)
T->>C: navigator.clipboard.writeText(textValue)
C-->>T: Resolved / Rejected (silently caught)
T-->>U: Show CheckOutlined for 2 s, then reset
note over U,C: DuckDB Seed Error Flow
participant B as DuckDbSeed.execute()
participant D as insert_csv_records()
participant E as SeedFailureException
U->>B: Trigger seed run
B->>B: null guard — db_connection is None?
B->>D: insert_csv_records(abs_path, table_name)
D-->>B: Exception (e.g. reserved keyword table name)
B->>E: raise SeedFailureException(table_name + err)
E-->>U: Descriptive error notification displayed
Greploops — Automatically fix all review issues by running /greploops in Claude Code. It iterates: fix, push, re-review, repeat until 5/5 confidence.
Use the Greptile plugin for Claude Code to query reviews, search comments, and manage custom context directly from your terminal.
Reviews (3): Last reviewed commit: "lint fix" | Re-trigger Greptile
What
CopyableCellwidgetNoneTypeAttributeErrorWhy
pivot.csv) raised'NoneType' object has no attribute 'insert_csv_records'with no meaningfulfeedback to the user
How
frontend/src/widgets/copyable-cell/— a reusable component that shows a copy icon on hover and copies cell content to clipboard. Integrated into theno-code model table column renderer replacing raw
<span>elementsDuckDbSeed.execute()with a null guard ondb_connectionand a try/except that raisesSeedFailureExceptionwith the table name in the errormessage
EnvCustomDataSectionrendering, allcustomDatastate/handlers,fetchProjectByConnection, and related imports fromNewEnv.jsxCan this PR break any existing features. If yes, please list possible items. If no, please explain why.
SeedFailureExceptioninstead of rawAttributeErrorcustom_datain API payloads and stores it (no migration needed), so no backwardcompatibility issue
Database Migrations
Env Config
Relevant Docs
Related Issues or PRs
Dependencies Versions
Notes on Testing
pivot.csv), run seed — should show a descriptive error notificationScreenshots
Checklist
I have read and understood the Contribution Guidelines.