Conversation
|
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
WalkthroughThis PR adds a complete flow version history feature. It introduces a new Changes
Sequence DiagramsequenceDiagram
actor User
participant Client as Frontend Client
participant API as Flow History API
participant Service as History Service
participant DB as Database
User->>Client: Click version to activate
Client->>API: POST /flows/{flow_id}/history/{history_id}/activate
API->>Service: get_flow_history_entry_or_raise (validate ownership)
Service->>DB: Query FlowHistory by ID
DB-->>Service: FlowHistory record
API->>Service: Optionally auto-save current draft
Service->>Service: create_flow_history_entry (current state)
Service->>DB: Insert new FlowHistory (snapshot)
DB-->>Service: Version created
API->>DB: Begin savepoint transaction
Service->>DB: Update Flow.data with historical version data
DB-->>Service: Confirmation
API->>DB: Commit savepoint
API-->>Client: Updated Flow with restored data
Client->>Client: applyFlowToCanvas (refresh canvas & inputs)
Client-->>User: Preview overlay synced to activated version
Estimated code review effort🎯 4 (Complex) | ⏱️ ~70 minutes 🚥 Pre-merge checks | ✅ 3 | ❌ 4❌ Failed checks (1 error, 3 warnings)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
|
✅ Migration Validation Passed All migrations follow the Expand-Contract pattern correctly. |
Codecov Report❌ Patch coverage is ❌ Your project status has failed because the head coverage (42.37%) is below the target coverage (60.00%). You can increase the head coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## main #11859 +/- ##
==========================================
+ Coverage 37.35% 37.46% +0.10%
==========================================
Files 1592 1616 +24
Lines 78304 79014 +710
Branches 11826 11936 +110
==========================================
+ Hits 29247 29599 +352
- Misses 47435 47761 +326
- Partials 1622 1654 +32
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
src/backend/base/langflow/services/database/models/flow_history/model.py
Outdated
Show resolved
Hide resolved
…gflow into workflow-history # Conflicts: # .secrets.baseline # src/frontend/package-lock.json # src/frontend/src/pages/FlowPage/components/flowSidebarComponent/index.tsx
* Update language from history to version * more language updates history -> version * more language updates history -> version * capture original draft at mount / restore * Renames files from history to version * clean up dead code, some more renames * more naming fixes * more naming fixes * Fix API endpoint language * [autofix.ci] apply automated fixes * version -> versions * ignore warning --------- Co-authored-by: Deon Sanchez <69873175+deon-sanchez@users.noreply.github.com> Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Adds version control for individual Flows.
Summary by CodeRabbit
Release Notes
New Features
Bug Fixes
Tests