-
Notifications
You must be signed in to change notification settings - Fork 3.3k
feat(description): add deployment version descriptions #3048
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. |
Greptile OverviewGreptile SummaryAdded description field to deployment versions with AI generation capabilities. The implementation includes database migration, API endpoint updates, and a new modal UI for viewing/editing descriptions. Successfully refactored to use TanStack Query mutations, eliminating the Key changes:
Implementation notes:
Confidence Score: 5/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant User
participant VersionsUI as Versions Component
participant Modal as VersionDescriptionModal
participant Hook as useUpdateDeploymentVersion
participant GenHook as useGenerateVersionDescription
participant API as /api/workflows/[id]/deployments/[version]
participant WandAPI as /api/wand
participant CompareLib as compare.ts
participant QueryClient as TanStack QueryClient
participant DB as Database
User->>VersionsUI: Click FileText icon or "Add description"
VersionsUI->>Modal: Open modal with current description
alt Generate Description
User->>Modal: Click "Generate" button
Modal->>GenHook: mutate({ workflowId, version })
GenHook->>API: GET /deployments/{version} (current)
API->>DB: Fetch current state
DB-->>GenHook: Current workflow state
GenHook->>API: GET /deployments/{version-1} (previous)
API->>DB: Fetch previous state
DB-->>GenHook: Previous workflow state
GenHook->>CompareLib: generateWorkflowDiffSummary(current, previous)
CompareLib-->>GenHook: WorkflowDiffSummary
GenHook->>CompareLib: formatDiffSummaryForDescription(summary)
CompareLib-->>GenHook: Formatted diff text
GenHook->>WandAPI: POST /api/wand (streaming)
loop Stream chunks
WandAPI-->>Modal: Stream chunk
Modal->>Modal: Update textarea with accumulated content
end
WandAPI-->>GenHook: Complete
end
User->>Modal: Edit description and click "Save"
Modal->>Hook: mutate({ workflowId, version, description })
Hook->>API: PATCH /deployments/{version}
API->>DB: UPDATE workflow_deployment_version
DB-->>API: Updated record
API-->>Hook: Success response
Hook->>QueryClient: invalidateQueries(deploymentKeys.versions)
QueryClient->>VersionsUI: Auto-refetch versions
Hook-->>Modal: onSuccess callback
Modal->>Modal: Close modal
Modal-->>VersionsUI: Update complete
VersionsUI->>User: Show updated description in tooltip
|
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.
6 files reviewed, 1 comment
Additional Comments (1)
Prompt To Fix With AIThis is a comment left during a code review.
Path: apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/deploy/components/deploy-modal/components/general/components/versions.tsx
Line: 259:259
Comment:
`block` and `flex` conflict - `block` display is overridden by `flex`
```suggestion
className={clsx('flex items-center gap-[4px] truncate', ROW_TEXT_CLASS)}
```
How can I resolve this? If you propose a fix, please make it concise. |
...s/deploy/components/deploy-modal/components/general/components/version-description-modal.tsx
Outdated
Show resolved
Hide resolved
...s/deploy/components/deploy-modal/components/general/components/version-description-modal.tsx
Show resolved
Hide resolved
|
@greptile |
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.
4 files reviewed, no comments
...s/deploy/components/deploy-modal/components/general/components/version-description-modal.tsx
Outdated
Show resolved
Hide resolved
...s/panel/components/deploy/components/deploy-modal/components/general/components/versions.tsx
Show resolved
Hide resolved
|
@greptile |
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.
5 files reviewed, no comments
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.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
Summary
Type of Change
Testing
Tested manually
Checklist