Skip to content

Make thumbnails of files on other machines - #166

Merged
dhh merged 2 commits into
mainfrom
remote-thumbnails
Nov 18, 2026
Merged

dhh merged 2 commits into
mainfrom
remote-thumbnails

Conversation

@dhh

@dhh dhh commented Nov 18, 2026

Copy link
Copy Markdown
Contributor

A file on another machine (a Tailscale machine's, mounted by GVfs) got no thumbnail and no preview from thumbnailers given a URI: they ask GIO for the file, and GIO turns a path under the GVfs mounts back into its network address, sftp://…, which most can't open. Papers, which makes PDFs' thumbnails, said so ("not an absolute URI using the file scheme"), and every remote PDF showed the plain icon in its row and its details.

Such a file now goes to the thumbnailer by a link in its scratch folder, named with the file's extension, which reads through the mount the same and which GIO leaves a file. A remote PDF's 128 and 1024 pixel thumbnails now take 150ms between them.

Its failure was remembered, so it would never have been tried again. What failed is now remembered with the round it failed in, and one from before this is tried once more.

🤖 Generated with Claude Code

A file on another machine (a Tailscale machine's, mounted by GVfs) got
no thumbnail and no preview from thumbnailers given a URI: they ask GIO
for the file, and GIO turns a path under the GVfs mounts back into its
network address, sftp://…, which most can't open. Papers, which makes
PDFs' thumbnails, said so ("not an absolute URI using the file scheme"),
and every remote PDF showed the plain icon in its row and its details.

Such a file now goes to the thumbnailer by a link in its scratch folder,
named with the file's extension, which reads through the mount the same
and which GIO leaves a file. A remote PDF's 128 and 1024 pixel
thumbnails now take 150ms between them.

Its failure was remembered, so it would never have been tried again.
What failed is now remembered with the round it failed in, and one from
before this is tried once more.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@greptile-apps

greptile-apps Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The follow-up appears safe to merge; no new blocking issues were found.

Summary

Remote files reach thumbnailers through a temporary link, and older failure records allow another attempt. The follow-up adds a focused test for remote and local paths.

  • Remote files now get thumbnails from installed thumbnailers.
  • Older thumbnail failures get another chance.

Reviews (2) · Last reviewed commit: "Test that a file on another machine reac..." · Reviewed by Greptile

Comment thread src/thumbnails.cpp Resolved
Where GVfs mounts other machines is now given to Thumbnails (the real
place unless a test gives its own), so a test can put a file there: its
fake thumbnailer, given a URI, records it, and the test checks it's a
file:// link with the file's extension, outside the mounts, while the
thumbnail is kept under the file's own path, and that a file here goes
as it is. Without the link the test fails.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@dhh
dhh merged commit 5802efa into main Nov 18, 2026
2 checks passed
@dhh
dhh deleted the remote-thumbnails branch November 18, 2026 08:00
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