Page MenuHomePhorge

PHP 8.1 "strlen(null)" exception on UIExamples' Bars page
Closed, ResolvedPublic

Description

  1. PHP 8.2.6; Phorge at dd24c94b0741ae2c3fdf73d6e70d0a10e18ba010
  2. Enable prototype applications via ./bin/config set phabricator.show-prototypes true
  3. Go to Go to Developer UI Examples at http://phorge.localhost/uiexample/
  4. In the sidebar on the left, select Bars
[2023-06-02 19:15:36] EXCEPTION: (RuntimeException) strlen(): Passing null to parameter #1 ($string) of type string is deprecated at [<arcanist>/src/error/PhutilErrorHandler.php:261]
arcanist(head=master, ref.master=b325304b6e52), phorge(head=uiExamples, ref.master=dd24c94b0741, ref.uiExamples=dd24c94b0741)
  #0 <#2> PhutilErrorHandler::handleError(integer, string, string, integer) called at [<phorge>/src/view/phui/PHUISegmentBarSegmentView.php:58]
  #1 <#2> PHUISegmentBarSegmentView::getTagAttributes() called at [<phorge>/src/view/AphrontTagView.php:104]
  #2 <#2> phutil_escape_html(PHUISegmentBarSegmentView) called at [<phorge>/src/infrastructure/markup/render.php:139]
  #3 <#2> phutil_escape_html(array) called at [<phorge>/src/infrastructure/markup/render.php:97]
  #4 <#2> phutil_tag(string, array, array) called at [<phorge>/src/view/phui/PHUISegmentBarView.php:52]
  #5 <#2> PHUISegmentBarView::getTagContent() called at [<phorge>/src/view/AphrontTagView.php:161]
  #6 <#2> AphrontTagView::render() called at [<phorge>/src/view/AphrontView.php:222]
  #7 <#2> AphrontView::producePhutilSafeHTML() called at [<phorge>/src/infrastructure/markup/render.php:115]
  #8 <#2> phutil_escape_html(PHUISegmentBarView) called at [<phorge>/src/infrastructure/markup/render.php:171]
  #9 <#2> phutil_implode_html(PhutilSafeHTML, array) called at [<phorge>/src/applications/uiexample/examples/PhabricatorAphrontBarUIExample.php:61]
  #10 <#2> PhabricatorAphrontBarUIExample::renderRainbow() called at [<phorge>/src/applications/uiexample/examples/PhabricatorAphrontBarUIExample.php:15]
  #11 <#2> PhabricatorAphrontBarUIExample::renderExample() called at [<phorge>/src/applications/uiexample/controller/PhabricatorUIExampleRenderController.php:35]
  #12 <#2> PhabricatorUIExampleRenderController::handleRequest(AphrontRequest) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:284]
  #13 phlog(RuntimeException) called at [<phorge>/src/aphront/handler/PhabricatorDefaultRequestExceptionHandler.php:41]
  #14 PhabricatorDefaultRequestExceptionHandler::handleRequestThrowable(AphrontRequest, RuntimeException) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:751]
  #15 AphrontApplicationConfiguration::handleThrowable(RuntimeException) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:296]
  #16 AphrontApplicationConfiguration::processRequest(AphrontRequest, PhutilDeferredLog, AphrontPHPHTTPSink, MultimeterControl) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:203]
  #17 AphrontApplicationConfiguration::runHTTPRequest(AphrontPHPHTTPSink) called at [<phorge>/webroot/index.php:35]