mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-10-27 16:02:43 +00:00
fix: stop starred items showing a starred removal in the editor diff (#12017)
* fix: stop starred items showing a starred removal in the editor diff Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * fix: ignore starred in every value diff Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
83ea0ef068
commit
35be14ea27
@@ -514,8 +514,7 @@
|
||||
// the draft's `draft_path` so the topbar shows the pending name, which after
|
||||
// someone renames the item still names the old location. Comparing against
|
||||
// that fetches the row left behind there instead of the live one.
|
||||
path: userDraftPath || initialPath,
|
||||
withStarredInfo: true
|
||||
path: userDraftPath || initialPath
|
||||
})
|
||||
// A superseded opening must not write these: the current one would then render
|
||||
// and offer Take latest against the older head.
|
||||
|
||||
@@ -693,8 +693,7 @@
|
||||
// the user has typed, so after someone renames the item it still names
|
||||
// the old location and this would compare against the archived row left
|
||||
// there. Resolving by the row is what lets the diff show the rename.
|
||||
path: userDraftPath || initialPath,
|
||||
withStarredInfo: true
|
||||
path: userDraftPath || initialPath
|
||||
})
|
||||
|
||||
// A superseded opening must not write these: the current one would then render
|
||||
|
||||
@@ -380,8 +380,7 @@
|
||||
async function syncWithDeployed(opening?: number) {
|
||||
const deployedApp = await AppService.getAppByPath({
|
||||
workspace: $workspaceStore!,
|
||||
path: $appPath!,
|
||||
withStarredInfo: true
|
||||
path: $appPath!
|
||||
})
|
||||
|
||||
// A superseded opening must not write these: the current one would then render
|
||||
|
||||
@@ -479,8 +479,7 @@
|
||||
async function syncWithDeployed(opening?: number) {
|
||||
const deployedApp = await AppService.getAppByPath({
|
||||
workspace: opWorkspace!,
|
||||
path: appPath!,
|
||||
withStarredInfo: true
|
||||
path: appPath!
|
||||
})
|
||||
|
||||
// A superseded opening must not write these: the current one would then render
|
||||
|
||||
@@ -367,7 +367,8 @@ describe('cleanValueProperties', () => {
|
||||
'edited_by',
|
||||
'workspace_id',
|
||||
'parent_hashes',
|
||||
'lock_error_logs'
|
||||
'lock_error_logs',
|
||||
'starred'
|
||||
]
|
||||
|
||||
it('strips every server-managed bookkeeping key', () => {
|
||||
|
||||
@@ -1422,7 +1422,8 @@ function replaceFalseWithUndefinedRec(obj: any) {
|
||||
// `hash` is the deployed version's identity, `assets` is re-derived from the
|
||||
// script content by the editor, and `inherited_labels` is computed at read time
|
||||
// from the parent folder — none is editable content, so all three are noise in a
|
||||
// fork/workspace or version diff.
|
||||
// fork/workspace or version diff. `starred` is the viewer's own favorite flag, and a
|
||||
// starred item's `starred: true` survives `replaceFalseWithUndefined`.
|
||||
//
|
||||
// `lock` and `extra_perms` are deliberately NOT in this set: both are legitimate,
|
||||
// user-meaningful fields in some diff contexts (lockfile changes in version-to-version
|
||||
@@ -1447,7 +1448,8 @@ const CLEANED_VALUE_KEYS = new Set([
|
||||
'edited_by',
|
||||
'workspace_id',
|
||||
'parent_hashes',
|
||||
'lock_error_logs'
|
||||
'lock_error_logs',
|
||||
'starred'
|
||||
])
|
||||
|
||||
export function cleanValueProperties(obj: Value) {
|
||||
|
||||
Reference in New Issue
Block a user