Page MenuHomePhabricator

Regenerating thumbnails for memes is difficult
Closed, DuplicatePublic

Description

On our Phabricator installation, we have a bunch of old macros with broken thumbnails. It took me a not-insignificant amount of time to figure out how to regenerate these thumbnails, and I consider myself to be a fairly advanced user.

broken-mem.png (431×434 px, 17 KB)

Basically, these are the steps that I had to follow:

  1. Used the macro.query API method to search for the name of a macro with a broken thumbnail.
  2. Copy the filePHID from the response.
  3. Pass the file PHID to phid.query to get the file's monogram.
  4. Navigate to /${FILE_PHID}.
  5. Click on "View Transforms".
  6. Click the "Regenerate" button next to the "pinboard" transformation.
  7. (At this point I stumbled into another bug, but I'll file that separately).

Event Timeline

Why did they need regenerating in the first place?

In T12950#230520, @chad wrote:

Why did they need regenerating in the first place?

I don't really know... the macros were created over three years ago and maybe the file transformation code had some issues back then?

This bug does exist on this server, but unclear why. Maybe related to size of image, but probably best solution is some command-line tool to regenerate all file transforms? I don't think making PHIDs easy to find inside the app is very user friendly.

I'm just going to merge this into T5258. There are two separate issues here:

  • Unclear communication when thumbnailing fails because of image sizes.
  • Loading the full meme list to generate all the memes usually brings the server to its knees, so most of them timeout and get a "too slow" cache written, which also isn't clearly communicated.