-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Nocodb - update data prop type #18481
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
Conversation
The latest updates on your projects. Learn more about Vercel for GitHub. 2 Skipped Deployments
|
WalkthroughMultiple NocoDB components update exported version fields across actions and sources. The app definition changes the propDefinitions entry for data from type "any" to "string". The package version increments. No logic, control flow, or method signatures are modified. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
Pre-merge checks and finishing touches❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
✨ Finishing touches
🧪 Generate unit tests
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. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
components/nocodb/actions/add-record/add-record.mjs (1)
8-8
: Version bump — consider guarding JSON.parse for better UXSince the
data
prop is now a string, invalid JSON will throw. Wrap parsing to surface a clear error.Example change inside methods.processEvent:
let data = this.data; if (typeof data === "string") { try { data = JSON.parse(data); } catch (err) { throw new Error("Invalid JSON for 'data'. Provide a valid JSON object string, e.g. {\"Name\":\"Alice\"}."); } } return this.nocodb.createTableRow({ tableId: this.tableId.value, data, $ });
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (10)
components/nocodb/actions/add-record/add-record.mjs
(1 hunks)components/nocodb/actions/delete-record/delete-record.mjs
(1 hunks)components/nocodb/actions/get-record/get-record.mjs
(1 hunks)components/nocodb/actions/list-records-matching-criteria/list-records-matching-criteria.mjs
(1 hunks)components/nocodb/actions/update-record/update-record.mjs
(1 hunks)components/nocodb/nocodb.app.mjs
(1 hunks)components/nocodb/package.json
(1 hunks)components/nocodb/sources/new-record-in-view/new-record-in-view.mjs
(1 hunks)components/nocodb/sources/new-record/new-record.mjs
(1 hunks)components/nocodb/sources/updated-record/updated-record.mjs
(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
- GitHub Check: Publish TypeScript components
- GitHub Check: Verify TypeScript components
- GitHub Check: Lint Code Base
🔇 Additional comments (9)
components/nocodb/actions/get-record/get-record.mjs (1)
8-8
: Version bump only — LGTMNo functional changes. Safe to merge.
components/nocodb/sources/new-record/new-record.mjs (1)
9-9
: Version bump only — LGTMNo behavior change.
components/nocodb/package.json (1)
3-3
: Package version bump — LGTMMatches component version updates.
components/nocodb/sources/updated-record/updated-record.mjs (1)
9-9
: Version bump only — LGTMNo logic changes.
components/nocodb/actions/delete-record/delete-record.mjs (1)
8-8
: Version bump only — LGTMNo functional change.
components/nocodb/actions/update-record/update-record.mjs (1)
8-8
: Version bump — LGTMParsing-guard suggestion for
data
already covered in related comments to avoid duplication.components/nocodb/nocodb.app.mjs (1)
94-97
: Refine data prop copy, guard JSON parse, and audit remaining any-typed props
- Replace
data
prop as follows:data: { - type: "string", - label: "data", - description: "Enter Json Formated data", + type: "string", + label: "Data", + description: "JSON-formatted object of field values to write. Example: {\"Name\":\"Alice\",\"Status\":\"Active\"}", },
- Wrap
JSON.parse
in add/update actions withtry/catch
to provide clear error messages.- Repo scan uncovered numerous
type: "any"
props (e.g. components/nocodb/…, zoom, visualping, xero, twist, etc.)—audit and convert these to prevent unsupported-property errors.components/nocodb/actions/list-records-matching-criteria/list-records-matching-criteria.mjs (1)
8-8
: Version bump aligns with the NocoDB update.Matches the broader release sync for these actions.
components/nocodb/sources/new-record-in-view/new-record-in-view.mjs (1)
8-8
: Source version update looks good.Consistent with the latest release wave.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @michelle0927, LGTM! Ready for QA!
Resolves #18473
Summary by CodeRabbit
Bug Fixes
Chores