Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

[BUG] Link click-to-copy sets clipboard as application/octet-stream, breaking paste in browsers (missing wl-copy --type on Wayland)

オープン 初心者向け
#313 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
72/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
linux, lua, neovim

調査の方向性

URL が :ClaudeCode からコピーされたときに使用されるリンクコピー・ハンドラーから開始し、wl-copy を直接呼び出しているのか、それとも vim.fn.setreg("+", url) を使用しているのかを追跡してください。wl-paste -l と Firefox または Chromium を使って修正を検証します。クリップボードが text/plain を公開し、URL が Wayland GUI アプリケーションに貼り付けられれば完了です。

索引モデルが issue の本文から書いたものです。

説明

bug needs-triage

Description

Clicking a link in the Claude terminal (opened via :ClaudeCode) copies it to
the clipboard with a notification confirming success, but the copied content
cannot be pasted into Firefox or Chromium on Wayland. Pasting into terminal
tools (wl-paste) works fine — only GUI applications using the standard
wl_data_device_manager protocol fail to read it.

Environment

  • OS: Kicksecure (Debian 13/trixie)
  • Compositor: labwc 0.8.3 (wlroots-based)
  • Terminal: kitty 0.41.1
  • Terminal provider: snacks (terminal.provider = "snacks")
  • wl-clipboard installed and confirmed working correctly for manual
    wl-copy --type text/plain calls

Steps to reproduce

  1. Open :ClaudeCode, get Claude to output a URL
  2. Double-click the link to copy it (plugin shows a "copied" notification)
  3. Try to paste (Ctrl+V) into Firefox's address bar, or Chromium's
  4. Nothing pastes; the field remains empty or unchanged

Diagnosis

Running wl-paste -l immediately after step 2 shows only:
application/octet-stream

By contrast:

  • wl-copy --type text/plain "url" followed by wl-paste -l correctly
    shows text/plain, text/plain;charset=utf-8, UTF8_STRING, etc., and
    pastes into Firefox/Chromium without issue.

  • A manual OSC 52 sequence sent directly to kitty (printf '\033]52;c;...')
    is also correctly typed as text/plain by kitty itself — so kitty's own
    OSC 52 → Wayland clipboard bridge is not at fault.

  • Plain echo "text" | wl-copy (no --type) also produces
    application/octet-stream on this system, matching wl-clipboard's
    documented limitation:

    wl-clipboard is not always able to detect that a MIME type is textual,
    which may break pasting into clients that expect textual formats, not
    application/something. The workaround […] is to specify the desired
    MIME type explicitly, such as wl-copy --type text/plain.
    — wl-copy(1) manpage, BUGS section

This strongly suggests the link-copy code path shells out to wl-copy
without an explicit --type, hitting this known/documented wl-clipboard
limitation, rather than going through Neovim's own clipboard provider
(vim.fn.setreg("+", url)), which I confirmed produces correctly-typed
text/plain clipboard content on the same system (tested via "+yy on a
normal buffer, checked with wl-paste -l).

Suggested fix

If the link-copy handler invokes wl-copy directly, adding --type text/plain (as documented as the standard workaround for this exact
wl-clipboard limitation) should resolve it. Alternatively, routing the copy
through Neovim's vim.fn.setreg("+", url) instead of a raw external
wl-copy call would also sidestep the issue, since that path is confirmed
to type the content correctly on this system.

Happy to test a fix if useful — this was fully reproducible and isolated
step by step (system Wayland clipboard, kitty's native OSC 52 handling, and
Neovim's own clipboard provider were all individually verified to work
correctly, narrowing the issue down to this specific code path).

主要言語
Lua
スター
3.1k
フォーク
217
PR マージ指標
30日以内にマージされた PR はありません

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

coder/claudecode.nvim のほかの issue

coder/claudecode.nvim の issue をすべて見る

似ている issue

Lua の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。