mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-09-10 16:05:58 +00:00
Editors used to store a renamed draft's target path in a separate
`draft_path` field (flows/apps/raw-apps) while keeping the deployed path in
the content's own `path`. This was redundant — the original/deployed path is
the URL — and it broke the "path already used" guard: editors passed the
renamed `draft_path` as the Path widget's `initialPath`, so reverting a draft
back to the original path falsely tripped "path already used".
Now every editor binds the Path widget to the content's own `path` (like the
script editor already did), and `initialPath` is always the deployed/original
path. A never-deployed draft seeds the baseline from its own friendly path so
the synthetic `draft_{uuid}` storage key isn't flagged as a rename.
The computed `draft_path` field on list/draft API responses is kept (it's how
the home/Review/Drafts lists render the friendly name) but is now sourced
uniformly from `value->>'path'` for all kinds.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>