Page MenuHomePhabricator

Parsoid does not always compute the proper image thumb URL
Closed, DuplicatePublic

Event Timeline

This is the instantcommons fallback, since the image is not present on enwiki it should be grabbed from commons. I was pretty certain that instantcommons works in Parsoid, I wonder what's going on. @Arlolra any ideas?

Further, it looks like this works on the command line:

$ php bin/parse.php --domain en.wikipedia.org --pageName Wikipedia:Wikipedia_for_Schools/Welcome/Mathematics --normalize=parsoid < /dev/null | fgrep versicolor
<div class="thumb"><span typeof="mw:Image"><a href="./File:Fisher_iris_versicolor_sepalwidth.png"><img resource="./File:Fisher_iris_versicolor_sepalwidth.png" src="//upload.wikimedia.org/wikipedia/commons/thumb/1/1d/Fisher_iris_versicolor_sepalwidth.png/270px-Fisher_iris_versicolor_sepalwidth.png" data-file-width="957" data-file-height="638" data-file-type="bitmap" height="120" width="180" srcset="//upload.wikimedia.org/wikipedia/commons/thumb/1/1d/Fisher_iris_versicolor_sepalwidth.png/405px-Fisher_iris_versicolor_sepalwidth.png 1.5x, //upload.wikimedia.org/wikipedia/commons/thumb/1/1d/Fisher_iris_versicolor_sepalwidth.png/540px-Fisher_iris_versicolor_sepalwidth.png 2x"/></a></span></div>

So this might be a misconfiguration (somehow) in how the rest_v1 endpoint is set up?

This is the instantcommons fallback, since the image is not present on enwiki it should be grabbed from commons. I was pretty certain that instantcommons works in Parsoid, I wonder what's going on. @Arlolra any ideas?

The other images on the page are also commons images so it's something specific to that image.

I did an ?action=purge and it seems to have fixed it. Maybe that image was recently moved to commons?

So, it existed on enwiki and Parsoid rendered the page and cached the result. And then got imported and deleted from enwiki.

In theory we should have invalidated our cache when the image was updated. So that's probably still a Parsoid-core integration bug we need to track down and fix, probably. Or else it will magically Just Work when we move from RestBASE to ParserCache.