-
Notifications
You must be signed in to change notification settings - Fork 1
Change DataModel creation interface #1403
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
🦋 Changeset detectedLatest commit: d590e91 The changes in this PR will be included in the next version bump. This PR includes changesets to release 17 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Summary of ChangesHello @vadimpiven, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly refactors the interface for creating Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
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.
Code Review
This pull request introduces a significant and well-executed refactoring of the DataModel creation interface. The new DataModelBuilder provides a much more type-safe and intuitive fluent API for defining data models with migrations. By using a state machine pattern with different builder classes, it cleverly enforces the correct sequence of method calls at compile-time, which is a great improvement for developer experience and robustness. The code is clean, well-documented, and the tests have been updated accordingly. I have one suggestion to correct a comment in a test file.
A point of consideration: this is a breaking API change, but the changeset is for a patch release. According to semantic versioning, breaking changes usually warrant at least a minor version bump. You may want to review if patch is the intended version increment.
7c11066 to
637c9b8
Compare
637c9b8 to
8ee686b
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1403 +/- ##
=======================================
Coverage 53.09% 53.10%
=======================================
Files 239 239
Lines 13364 13369 +5
Branches 2735 2736 +1
=======================================
+ Hits 7096 7099 +3
Misses 5367 5367
- Partials 901 903 +2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
| return { ...data, description: `Migrated: ${data.labels.join(', ')}` }; | ||
| }) | ||
| .create<BlockData>(() => ({ numbers: [], labels: [], description: '' })); | ||
| .init(() => ({ numbers: [], labels: [], description: '' })); |
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.
should we use classic build method?
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.
I do not think that would look good
No description provided.