Page MenuHomePhorge

Top level diffusion repository view fails under PHP 8.1 with passing null to trim()
Closed, ResolvedPublic

Description

Going to the top level diffusion repository view (eg https://my.phorge.site/source/myrepo) fails under PHP 8.1 with passing null to trim() error.

Stack Trace:

AH01071: Got error 'PHP message: [2023-06-30 07:34:03] EXCEPTION: (RuntimeException) trim(): Passing null to parameter
#1 ($string) of type string is deprecated at [<arcanist>/src/error/PhutilErrorHandler.php:261]PHP message: arcanist(head=master, ref.master=8130241a11ac, custom=4), phorge(head=master, ref.master=7c1487e4dcfa)PHP message:
#0 <#2> PhutilErrorHandler::handleError(integer, string, string, integer) called at [<arcanist>/src/error/PhutilErrorHandler.php:261]PHP message:
#1 <#2> trim(NULL, string) called at [<phorge>/src/applications/diffusion/view/DiffusionBrowseTableView.php:18]PHP message:
#2 <#2> phutil_tag(string, array, array) called at [<phorge>/src/infrastructure/javelin/markup.php:70]PHP message:
#3 <#2> phutil_escape_html(array) called at [<phorge>/src/infrastructure/markup/render.php:97]PHP message:
#4 <#2> phutil_tag(string, array, array) called at [<phorge>/src/view/phui/PHUITwoColumnView.php:242]PHP message:
#5 <#2> PHUITwoColumnView::buildFooter() called at [<phorge>/src/view/phui/PHUITwoColumnView.php:123]PHP message:
#6 <#2> PHUITwoColumnView::getTagContent() called at [<phorge>/src/view/AphrontTagView.php:161]PHP message:
#7 <#2> AphrontTagView::render() called at [<phorge>/src/view/AphrontView.php:222]PHP message:
#8 <#2> AphrontView::producePhutilSafeHTML() called at [<phorge>/src/infrastructure/markup/render.php:115]PHP message:
#9 <#2> phutil_escape_html(PHUITwoColumnView) called at [<phorge>/src/infrastructure/markup/render.php:139]PHP message:
#10 <#2> phutil_escape_html(array) called at [<phorge>/src/infrastructure/markup/render.php:171]PHP message:
#11 <#2> phutil_implode_html(string, array) called at [<phorge>/src/view/page/PhabricatorBarePageView.php:58]PHP message:
#12 <#2> PhabricatorBarePageView::willRenderPage() called at [<phorge>/src/view/page/PhabricatorStandardPageView.php:216]PHP message:
#13 <#2> PhabricatorStandardPageView::willRenderPage() called at [<phorge>/src/view/page/AphrontPageView.php:46]PHP message:
#14 <#2> AphrontPageView::render() called at [<phorge>/src/view/page/PhabricatorStandardPageView.php:904]PHP message:
#15 <#2> PhabricatorStandardPageView::produceAphrontResponse() called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:722]PHP message:
#16 <#2> AphrontApplicationConfiguration::produceResponse(AphrontRequest, PhabricatorStandardPageView) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:299]PHP message:
#17 phlog(RuntimeException) called at [<phorge>/src/aphront/handler/PhabricatorDefaultRequestExceptionHandler.php:41]PHP message:
#18 PhabricatorDefaultRequestExceptionHandler::handleRequestThrowable(AphrontRequest, RuntimeException) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:751]PHP message:
#19 AphrontApplicationConfiguration::handleThrowable(RuntimeException) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:337]PHP message:
#20 AphrontApplicationConfiguration::processRequest(AphrontRequest, PhutilDeferredLog, AphrontPHPHTTPSink, MultimeterControl) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:204]PHP message:
#21 AphrontApplicationConfiguration::runHTTPRequest(AphrontPHPHTTPSink) called at [<phorge>/webroot/index.php:35]'

Related Objects

View Standalone Graph
This task is connected to more than 200 other tasks. Only direct parents and subtasks are shown here. Use View Standalone Graph to show more of the graph.