Page MenuHomePhabricator

MediaWiki\Revision\RevisionAccessException: Not an available content version. (due to revision deleted content)
Open, Needs TriagePublicPRODUCTION ERROR

Description

Error
normalized_message
[{reqId}] {exception_url}   MediaWiki\Revision\RevisionAccessException: Not an available content version.
exception.trace
from /srv/mediawiki/php-1.40.0-wmf.21/includes/parser/Parsoid/Config/PageConfigFactory.php(171)
#0 /srv/mediawiki/php-1.40.0-wmf.21/includes/parser/Parsoid/ParsoidOutputAccess.php(460): MediaWiki\Parser\Parsoid\Config\PageConfigFactory->create(MediaWiki\Page\PageStoreRecord, NULL, MediaWiki\Revision\RevisionStoreRecord, NULL, NULL, array)
#1 /srv/mediawiki/php-1.40.0-wmf.21/includes/parser/Parsoid/ParsoidOutputAccess.php(244): MediaWiki\Parser\Parsoid\ParsoidOutputAccess->parse(MediaWiki\Page\PageStoreRecord, ParserOptions, array, MediaWiki\Revision\RevisionStoreRecord)
#2 /srv/mediawiki/php-1.40.0-wmf.21/extensions/DiscussionTools/includes/Hooks/HookUtils.php(134): MediaWiki\Parser\Parsoid\ParsoidOutputAccess->getParserOutput(MediaWiki\Page\PageStoreRecord, ParserOptions, MediaWiki\Revision\RevisionStoreRecord, integer)
#3 /srv/mediawiki/php-1.40.0-wmf.21/extensions/DiscussionTools/includes/ApiDiscussionToolsPageInfo.php(112): MediaWiki\Extension\DiscussionTools\Hooks\HookUtils::parseRevisionParsoidHtml(MediaWiki\Revision\RevisionStoreRecord, string)
#4 /srv/mediawiki/php-1.40.0-wmf.21/extensions/DiscussionTools/includes/ApiDiscussionToolsPageInfo.php(46): MediaWiki\Extension\DiscussionTools\ApiDiscussionToolsPageInfo->getThreadItemSet(array)
#5 /srv/mediawiki/php-1.40.0-wmf.21/includes/api/ApiMain.php(1901): MediaWiki\Extension\DiscussionTools\ApiDiscussionToolsPageInfo->execute()
#6 /srv/mediawiki/php-1.40.0-wmf.21/includes/api/ApiMain.php(878): ApiMain->executeAction()
#7 /srv/mediawiki/php-1.40.0-wmf.21/includes/api/ApiMain.php(849): ApiMain->executeActionWithErrorHandling()
#8 /srv/mediawiki/php-1.40.0-wmf.21/api.php(90): ApiMain->execute()
#9 /srv/mediawiki/php-1.40.0-wmf.21/api.php(45): wfApiMain()
#10 /srv/mediawiki/w/api.php(3): require(string)
#11 {main}
Notes
  • Low frequency
  • Dependent on user input from the api
  • Maybe should be a message to user rather than an exception? Unclear.

Details

Request URL
https://en.wikipedia.org/w/api.php?action=discussiontoolspageinfo&format=*&formatversion=*&oldid=*&page=*&uselang=*

Event Timeline

@daniel's team should probably be tagged here (I don't know the exact tag to use) as well as DiscussionTools -- seems related to the 'direct parsoid access' patches, but fundamentally seems to be about trying to invoke discussion tools on something which is not actually a talk page?

Umherirrender subscribed.

Code is:

		// If we have a revision record, check that we are allowed to see it.
		// Mirrors the check from RevisionRecord::getContent
		if (
			$revisionRecord !== null &&
			!$revisionRecord->audienceCan(
				RevisionRecord::DELETED_TEXT, RevisionRecord::FOR_PUBLIC
			)
		) {
			throw new RevisionAccessException( 'Not an available content version.' );
		}

When the api module gets oldid with revision deleted content it should not die. Reply tools on hidden text should just not shown.

Umherirrender renamed this task from MediaWiki\Revision\RevisionAccessException: Not an available content version. to MediaWiki\Revision\RevisionAccessException: Not an available content version. (due to revision deleted content).May 5 2023, 10:56 PM