Page MenuHomePhabricator

Erfgoedbot categorisation statistics always indicate 0
Closed, ResolvedPublic

Description

See https://commons.wikimedia.org/wiki/Commons:Monuments_database/Categorization/Statistics

Both the counts in the table and the edit summaries in the history

Updating categorization statistics. Total: 6980 Categorized: 0 Leftover: 6980

While I know for sure that some of these runs have categorised at least some pictures, and that the process concluded in one go.

But there are solid looking unit tests for these methods 🤔

Event Timeline

Is the cause as simple as forgetting a return statement on categorizeImage() when categorisation is successful?

Coincidentally that also seems to be a method without unit tests.

Is the cause as simple as forgetting a return statement on categorizeImage() when categorisation is successful?

Ah, good idea − will look into it…

Coincidentally that also seems to be a method without unit tests.

…after I’m done adding some tests on this method :)

Change 458483 had a related patch set uploaded (by Jean-Frédéric; owner: Jean-Frédéric):
[labs/tools/heritage@master] Correctly return status in categorizeImage

https://gerrit.wikimedia.org/r/458483

Change 458483 merged by jenkins-bot:
[labs/tools/heritage@master] Correctly return status in categorizeImage

https://gerrit.wikimedia.org/r/458483