Skip to content

release: 1.6.8 — files from sync paste in Dolphin; file URIs fixed on Python 3.14 - #112

Merged
davidboulay merged 1 commit into
mainfrom
fix/dolphin-file-paste
Nov 6, 2026
Merged

davidboulay merged 1 commit into
mainfrom
fix/dolphin-file-paste

Conversation

@davidboulay

Copy link
Copy Markdown
Owner

Problem

On KWin (CachyOS Plasma), pasting a file received over sync into Dolphin opened "enter a name for the text file" instead of pasting the file.

  1. Off cosmic-comp, copy_file sets the Wayland selection with a single wl-copy type, and for non-image files that was x-special/gnome-copied-files. Dolphin doesn't read that flavor and treats the clipboard as unknown data to save as a file.
  2. On Python 3.14, urllib.request.pathname2url("/abs") returns ///abs, so "file://" + … produced file://///home/....

Fix

  • The single Wayland flavor for a file reference is now text/uri-list (read by Dolphin, Nautilus/GTK and browsers). The XWayland owner still serves both flavors, and the no-owner xclip mirror now matches the Wayland flavor.
  • _file_uri() uses Path.as_uri(). It is applied in _file_parts, copy_file and the panel thumbnailer.
  • Bumped to 1.6.8.

Tests

scripts/recover_flavors_test.py covers the uri-list flavor off cosmic, three-slash URIs with escaping, both owner parts, and the xclip mirror. All scripts/*_test.py pass on Linux except mac_rich_copy_test.py, which needs AppKit (macOS only) and fails on main too.

🤖 Generated with Claude Code

… Python 3.14

Off cosmic-comp and Hyprland (KWin), copy_file's wl-copy carries the whole
offer for native apps, and it sent x-special/gnome-copied-files. Dolphin
ignores that flavor and offers to save the bytes as a new text file, so a
zip synced from the Mac asked for a file name instead of pasting. Send
text/uri-list instead, which every file manager reads; the no-owner xclip
mirror now carries the same flavor.

Python 3.14's pathname2url returns "///abs/path", so "file://" + it gave
file://///abs/path. Build URIs with Path.as_uri() in the Wayland backend
and the thumbnailer.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@davidboulay
davidboulay merged commit 3fa5f1e into main Nov 6, 2026
4 checks passed
@davidboulay
davidboulay deleted the fix/dolphin-file-paste branch November 6, 2026 12:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant