Skip to content

fix: remint clip alias on paste to avoid duplicate alias errors - #188

Merged
dazzatronus merged 1 commit into
mainfrom
fix/paste-remint-clip-alias
Sep 16, 2026
Merged

dazzatronus merged 1 commit into
mainfrom
fix/paste-remint-clip-alias

Conversation

@dazzatronus

Copy link
Copy Markdown
Contributor

Why

Pasting a clip (internal clipboard or OS clip JSON) stripped id but kept alias. Resolve then threw Duplicate alias "…" found when the source clip was still on the timeline. Same failure mode for user aliases (e.g. VOICEOVER) and auto source_* aliases.

Fix

Always remint paste identity when an alias is present: clear the source id, mint a new id, and set alias via existing generateAlias. Applied in:

  • pasteClip (selection manager)
  • addClipFromJson / addTracksFromJson (OS clipboard paste paths)

Non-paste add/update paths are unchanged.

Verify

npm test -- --testPathPatterns=remint-pasted-alias --testPathPatterns=edit-clip-operations --testNamePattern='remint|pasteClip remints|addClipFromJson remints'

Manual: npm run dev, copy an aliased clip, paste at playhead — paste succeeds; original alias unchanged; pasted clip gets a new source_* alias.

Risk

Low. Paste-only. Clips without aliases behave as before (id stripped only). Pasted aliased clips no longer keep the source alias name (they get a fresh source_*), which is intentional to avoid collisions.

Paste previously stripped id but kept alias, so resolve threw on
Duplicate alias. Remint via generateAlias in pasteClip, addClipFromJson,
and addTracksFromJson.
@dazzatronus
dazzatronus merged commit a404f88 into main Sep 16, 2026
1 check passed
@dazzatronus
dazzatronus deleted the fix/paste-remint-clip-alias branch September 16, 2026 19:19
github-actions Bot pushed a commit that referenced this pull request Sep 16, 2026
## [2.19.6](v2.19.5...v2.19.6) (2026-09-16)

### Bug Fixes

* remint clip alias on paste to avoid duplicate alias resolve errors ([#188](#188)) ([a404f88](a404f88))
@github-actions

Copy link
Copy Markdown

🎉 This PR is included in version 2.19.6 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant