Page MenuHomePhabricator

RuntimeException: Conflicting keys (imagerepository) when attempting to merge element 153124452
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error
  • mwversion: 1.45.0-wmf.15
  • timestamp: 2025-08-20T12:06:14.178Z
  • phpversion: 8.1.33
  • reqId: aafa2868-6236-4f3c-8cfb-0d41ff3d8a0d
  • Find reqId in Logstash
normalized_message
[{reqId}] {exception_url}   RuntimeException: Conflicting keys (imagerepository) when attempting to merge element 153124452
FrameLocationCall
from/srv/mediawiki/php-1.45.0-wmf.15/includes/api/ApiResult.php(318)
#0/srv/mediawiki/php-1.45.0-wmf.15/includes/api/ApiResult.php(427)MediaWiki\Api\ApiResult::setValue(array, int, array, int)
#1/srv/mediawiki/php-1.45.0-wmf.15/includes/api/ApiQueryImageInfo.php(200)MediaWiki\Api\ApiResult->addValue(array, int, array)
#2/srv/mediawiki/php-1.45.0-wmf.15/includes/api/ApiQuery.php(754)MediaWiki\Api\ApiQueryImageInfo->execute()
#3/srv/mediawiki/php-1.45.0-wmf.15/includes/api/ApiMain.php(2033)MediaWiki\Api\ApiQuery->execute()
#4/srv/mediawiki/php-1.45.0-wmf.15/includes/api/ApiMain.php(955)MediaWiki\Api\ApiMain->executeAction()
#5/srv/mediawiki/php-1.45.0-wmf.15/includes/api/ApiMain.php(926)MediaWiki\Api\ApiMain->executeActionWithErrorHandling()
#6/srv/mediawiki/php-1.45.0-wmf.15/includes/api/ApiEntryPoint.php(152)MediaWiki\Api\ApiMain->execute()
#7/srv/mediawiki/php-1.45.0-wmf.15/includes/MediaWikiEntryPoint.php(198)MediaWiki\Api\ApiEntryPoint->execute()
#8/srv/mediawiki/php-1.45.0-wmf.15/api.php(44)MediaWiki\MediaWikiEntryPoint->run()
#9/srv/mediawiki/w/api.php(3)require(string)
#10{main}
Impact
Notes

Details

Event Timeline

aaron triaged this task as Medium priority.Aug 22 2025, 3:21 AM
aaron subscribed.

This error seemed to happen in the past 2025/06/03 in addition to around 2025/08/30. In any case, I don't see why this error is possible from a glance.

FGoodwin lowered the priority of this task from Medium to Low.Aug 28 2025, 4:10 PM
FGoodwin subscribed.

Moving to bugs and chores with a low priority status. This task looks to be within the scope of our team.

The number in the error message is a page id, this refers to a pdf and webp file with timed text.
https://commons.wikimedia.org/?curid=149491560
https://commons.wikimedia.org/?curid=153124452

The api query is a search query.
Maybe the search result contains the file twice as the search word is on two pages of the multipage pdf
For this it would be helpful to know the search term and use the api url without generator to see the result.

In that case the problem is prop=imageinfo|videoinfo, videoinfo extends imageinfo and both modules setting the imagerepository key (outside of videoinfo or imageinfo key)

(Maybe a new gadget is using this query, not sure if UA or referer can help to find somebody to send a mail. Hopefully the requester stops itself as this is not working.)

https://commons.wikimedia.org/w/api.php?action=query&generator=search&gsrlimit=1&gsrnamespace=6&gsrsearch=Nil+nehri%20filetype:video&iiprop=url|extmetadata|mime&iiurlwidth=800&prop=videoinfo
https://commons.wikimedia.org/w/api.php?action=query&generator=search&gsrlimit=1&gsrnamespace=6&gsrsearch=Nil+nehri%20filetype:video&iiprop=url|extmetadata|mime&iiurlwidth=800&prop=imageinfo

Change #1195052 had a related patch set uploaded (by Umherirrender; author: Umherirrender):

[mediawiki/core@master] api: Allow ApiResult to override imagerepository key in prop=imageinfo

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

Change #1195052 merged by jenkins-bot:

[mediawiki/core@master] api: Allow ApiResult to override imagerepository key in prop=imageinfo

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

Change #1198654 had a related patch set uploaded (by Reedy; author: Umherirrender):

[mediawiki/core@REL1_44] api: Allow ApiResult to override imagerepository key in prop=imageinfo

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

Change #1198655 had a related patch set uploaded (by Reedy; author: Umherirrender):

[mediawiki/core@REL1_43] api: Allow ApiResult to override imagerepository key in prop=imageinfo

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

Change #1198658 had a related patch set uploaded (by Reedy; author: Reedy):

[mediawiki/core@master] ApiResult: Update @since backport for IGNORE_CONFLICT_KEYS

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

Change #1198655 merged by jenkins-bot:

[mediawiki/core@REL1_43] api: Allow ApiResult to override imagerepository key in prop=imageinfo

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

Change #1198654 merged by jenkins-bot:

[mediawiki/core@REL1_44] api: Allow ApiResult to override imagerepository key in prop=imageinfo

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

Change #1198658 merged by jenkins-bot:

[mediawiki/core@master] ApiResult: Update @since backport for IGNORE_CONFLICT_KEYS

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

Umherirrender claimed this task.