Page MenuHomePhabricator

Fix variable issue on Conpherence draft saving pathway
ClosedPublic

Authored by epriestley on Feb 24 2014, 7:48 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Sep 23, 1:12 PM
Unknown Object (File)
Mon, Sep 23, 1:12 PM
Unknown Object (File)
Mon, Sep 23, 1:12 PM
Unknown Object (File)
Mon, Sep 23, 1:09 PM
Unknown Object (File)
Fri, Sep 13, 11:31 PM
Unknown Object (File)
Wed, Sep 11, 6:16 PM
Unknown Object (File)
Sep 4 2024, 10:20 AM
Unknown Object (File)
Sep 1 2024, 2:50 PM
Subscribers

Details

Summary

When we save a Conpherence draft, the draft part works fine but $xactions never gets defined, so this gets hit a little later on:

[24-Feb-2014 11:46:10] WARNING: [pool www] child 82805 said into stderr: "NOTICE: PHP message: [2014-02-24 11:46:10] EXCEPTION: (RuntimeException) Undefined variable: xactions at [/INSECURE/devtools/libphutil/src/error/PhutilErrorHandler.php:211]"
[24-Feb-2014 11:46:10] WARNING: [pool www] child 82805 said into stderr: "NOTICE: PHP message:   #0 PhutilErrorHandler::handleError(8, Undefined variable: xactions, /INSECURE/devtools/phabricator/src/applications/conpherence/controller/ConpherenceUpdateController.php, 122, Array of size 13 starting with: { request => Object AphrontRequest }) called at [/INSECURE/devtools/phabricator/src/applications/conpherence/controller/ConpherenceUpdateController.php:122]"
[24-Feb-2014 11:46:10] WARNING: [pool www] child 82805 said into stderr: "NOTICE: PHP message:   #1 ConpherenceUpdateController::processRequest() called at [/INSECURE/devtools/phabricator/webroot/index.php:87]"

Instead, define $xactions.

Test Plan
  • Type into Conpherence while tailing the error log.
  • After patch, clean error log.

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

Thank you sir. Apologies for putting poop in your error log.

haha, no problem. I think we intentionally ignore errors in ShapedRequest, which is most of the root cause here. A more systematic fix might be to ignore errors only in production, but as long as we're only hitting this kind of thing a couple times a year I'm inclined not to bother.