Page MenuHomePhabricator

Call to a member function serialize() on null
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error

message
Call to a member function serialize() on null

Details

Request ID
6008a6a0-0c53-11ea-9bf2-572ded534af2
Request URL
https://en.wikipedia.org/w/rest.php/en.wikipedia.org/v3/page/pagebundle/Draft%3AMyopia_(band)/927026118
Stack Trace
exception.trace
#0 /srv/deployment/parsoid/deploy-cache/revs/766562458022b36f7d641065bcb7161e512d650c/src/src/Wt2Html/PageConfigFrame.php(34): MWParsoid\Config\PageContent->getContent(string)
#1 /srv/deployment/parsoid/deploy-cache/revs/766562458022b36f7d641065bcb7161e512d650c/src/src/Config/Env.php(264): Parsoid\Wt2Html\PageConfigFrame->__construct(Parsoid\Config\Env, MWParsoid\Config\PageConfig, MWParsoid\Config\SiteConfig, boolean)
#2 /srv/deployment/parsoid/deploy-cache/revs/766562458022b36f7d641065bcb7161e512d650c/src/extension/src/Rest/Handler/ParsoidHandler.php(356): Parsoid\Config\Env->__construct(MWParsoid\Config\SiteConfig, MWParsoid\Config\PageConfig, MWParsoid\Config\DataAccess, array)
#3 /srv/deployment/parsoid/deploy-cache/revs/766562458022b36f7d641065bcb7161e512d650c/src/extension/src/Rest/Handler/PageHandler.php(33): MWParsoid\Rest\Handler\ParsoidHandler->createEnv(string, integer, boolean)
#4 /srv/mediawiki/php-1.35.0-wmf.5/includes/Rest/Router.php(315): MWParsoid\Rest\Handler\PageHandler->execute()
#5 /srv/mediawiki/php-1.35.0-wmf.5/includes/Rest/Router.php(285): MediaWiki\Rest\Router->executeHandler(MWParsoid\Rest\Handler\PageHandler)
#6 /srv/mediawiki/php-1.35.0-wmf.5/includes/Rest/EntryPoint.php(116): MediaWiki\Rest\Router->execute(MediaWiki\Rest\RequestFromGlobals)
#7 /srv/mediawiki/php-1.35.0-wmf.5/includes/Rest/EntryPoint.php(83): MediaWiki\Rest\EntryPoint->execute()
#8 /srv/mediawiki/php-1.35.0-wmf.5/rest.php(31): MediaWiki\Rest\EntryPoint::main()
#9 /srv/mediawiki/w/rest.php(3): require(string)
#10 {main}

Related Objects

Event Timeline

ssastry triaged this task as Medium priority.Nov 21 2019, 5:34 PM

Change 557101 had a related patch set uploaded (by Sbailey; owner: Sbailey):
[mediawiki/services/parsoid@master] Fix for request with revID that has no content

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

I configured my local wiki to allow:

GroupPermissions['administrators']['suppressrevision'] = true;
and added 'suppressor' for revisions to my administrators
http://localhost:8080/index.php?title=Special%3AUserRights
account. I then used local user account to edit a page
and then used my admin account to edit it again. I captured
the other users edit oldid and used the admin account to
access the page history and used 'Change visibility of selected
revisions' button on right to suppress the ability to read that
old revision. This reproduced the bug and I found that
Api/PageConfig makeRequest( ... ) was not returned the [pages]
as designed, but our code was accessing that associative key
anyway without protection causing a crash.

Change 557101 merged by jenkins-bot:
[mediawiki/services/parsoid@master] Fix for request with revID that has no content

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