-
Notifications
You must be signed in to change notification settings - Fork 1
feat: one-step generate, add clear cli command #91
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
WalkthroughThe changes introduce improved error handling in the mapping logic by explicitly raising a descriptive error when a source table mapping is missing. Additionally, the CLI's Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant CLI
participant BuildProcess
participant AIGenerator
User->>CLI: morph build [--with-generate]
CLI->>BuildProcess: Run build steps
BuildProcess-->>CLI: Build complete
alt with-generate flag is set
CLI->>AIGenerator: Run AI mapping generation
AIGenerator-->>CLI: Generation complete
end
CLI-->>User: Done
sequenceDiagram
participant User
participant CLI
participant AIGenerator
User->>CLI: morph generate
CLI->>AIGenerator: Run AI mapping generation
AIGenerator-->>CLI: Generation complete
CLI-->>User: Done
Poem
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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
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 (4)
.github/workflows/generate-command.yml (4)
112-112
: Verify and refine the new build invocation
The workflow now invokesuv run morph build ... --with-generate
instead of the previousmorph generate
command. Please confirm that:
- The
build
command internally handles the regeneration and confirmation flags (formerly--regenerate-all --auto-confirm
).- You no longer need the explicit flags, or if you do, add them back.
- Since
source_name
is markedrequired: true
, the fallback|| 'klaviyo'
is redundant—consider removing it for clarity.
48-49
: Update the comment to reflect the new command
The comment still reads “usingmorph generate
command,” but the step now runsmorph build --with-generate
. Update this text to keep documentation in sync.
105-105
: Rename the step for clarity
The step is named “Run generate command,” but it now performs a build + generate operation. Rename it to something like “Run build command with generation” to accurately describe the action.
111-111
: Align the inline comment with the actual command
The inline comment above the command still says “# Run morph generate…”. Please update this to reflect that the workflow runsmorph build … --with-generate
.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (5)
.github/workflows/generate-command.yml
(1 hunks)src/morph/ai/map.py
(2 hunks)src/morph/cli/main.py
(6 hunks)src/morph/resources.py
(3 hunks)src/transforms/hubspot/config.yml
(1 hunks)
✅ Files skipped from review due to trivial changes (2)
- src/transforms/hubspot/config.yml
- src/morph/resources.py
🚧 Files skipped from review as they are similar to previous changes (2)
- src/morph/ai/map.py
- src/morph/cli/main.py
Summary by CodeRabbit
New Features
--with-generate
option to the build command, allowing users to trigger AI-based generation of transform mappings as part of the build process.clear
command to remove generated build artifacts and related directories.Bug Fixes
Refactor
Configuration