Page MenuHomePhorge

PHP 8.1 "strlen(null)" exceptions block rendering "Browse Projects" overlay dialog
Closed, ResolvedPublic

Description

  1. PHP 8.2.5; Phorge at 427bb78ec47ad031360e68e27d0883e21361a36d with D25179 on top
  2. (As a non-admin:) Go to http://phorge.localhost/maniphest/task/edit/form/default/ to create a task
  3. Click the button next to the Tags input field
[2023-05-10 14:14:46] EXCEPTION: (RuntimeException) strlen(): Passing null to parameter #1 ($string) of type string is deprecated at [<arcanist>/src/error/PhutilErrorHandler.php:261]
arcanist(head=renderDashboardTabPanelContent, ref.master=d47289622650, ref.renderDashboardTabPanelContent=d47289622650), phorge(head=master, ref.master=427bb78ec47a)
  #0 <#2> PhutilErrorHandler::handleError(integer, string, string, integer) called at [<phorge>/src/applications/project/typeahead/PhabricatorProjectDatasource.php:88]
  #1 <#2> PhabricatorProjectDatasource::loadResults() called at [<phorge>/src/applications/typeahead/datasource/PhabricatorTypeaheadDatasource.php:142]
  #2 <#2> PhabricatorTypeaheadDatasource::loadResultsForPhase(string, integer) called at [<phorge>/src/applications/typeahead/datasource/PhabricatorTypeaheadCompositeDatasource.php:136]
  #3 <#2> PhabricatorTypeaheadCompositeDatasource::loadResultsForPhase(string, integer) called at [<phorge>/src/applications/typeahead/datasource/PhabricatorTypeaheadCompositeDatasource.php:48]
  #4 <#2> PhabricatorTypeaheadCompositeDatasource::loadResults() called at [<phorge>/src/applications/typeahead/controller/PhabricatorTypeaheadModularDatasourceController.php:91]
  #5 <#2> PhabricatorTypeaheadModularDatasourceController::handleRequest(AphrontRequest) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:284]
  #6 phlog(RuntimeException) called at [<phorge>/src/aphront/handler/PhabricatorDefaultRequestExceptionHandler.php:41]
  #7 PhabricatorDefaultRequestExceptionHandler::handleRequestThrowable(AphrontRequest, RuntimeException) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:751]
  #8 AphrontApplicationConfiguration::handleThrowable(RuntimeException) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:296]
  #9 AphrontApplicationConfiguration::processRequest(AphrontRequest, PhutilDeferredLog, AphrontPHPHTTPSink, MultimeterControl) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:203]
  #10 AphrontApplicationConfiguration::runHTTPRequest(AphrontPHPHTTPSink) called at [<phorge>/webroot/index.php:35]

Fix that exception; get next exception:

[2023-05-10 14:19:11] EXCEPTION: (RuntimeException) strlen(): Passing null to parameter #1 ($string) of type string is deprecated at [<arcanist>/src/error/PhutilErrorHandler.php:261]
arcanist(head=renderDashboardTabPanelContent, ref.master=d47289622650, ref.renderDashboardTabPanelContent=d47289622650), phorge(head=typeaheadProjects, ref.master=427bb78ec47a, ref.typeaheadProjects=4d9719539773)
  #0 <#2> PhutilErrorHandler::handleError(integer, string, string, integer) called at [<phorge>/src/applications/project/typeahead/PhabricatorProjectDatasource.php:137]
  #1 <#2> PhabricatorProjectDatasource::loadResults() called at [<phorge>/src/applications/typeahead/datasource/PhabricatorTypeaheadDatasource.php:142]
  #2 <#2> PhabricatorTypeaheadDatasource::loadResultsForPhase(string, integer) called at [<phorge>/src/applications/typeahead/datasource/PhabricatorTypeaheadCompositeDatasource.php:136]
  #3 <#2> PhabricatorTypeaheadCompositeDatasource::loadResultsForPhase(string, integer) called at [<phorge>/src/applications/typeahead/datasource/PhabricatorTypeaheadCompositeDatasource.php:48]
  #4 <#2> PhabricatorTypeaheadCompositeDatasource::loadResults() called at [<phorge>/src/applications/typeahead/controller/PhabricatorTypeaheadModularDatasourceController.php:91]
  #5 <#2> PhabricatorTypeaheadModularDatasourceController::handleRequest(AphrontRequest) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:284]
  #6 phlog(RuntimeException) called at [<phorge>/src/aphront/handler/PhabricatorDefaultRequestExceptionHandler.php:41]
  #7 PhabricatorDefaultRequestExceptionHandler::handleRequestThrowable(AphrontRequest, RuntimeException) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:751]
  #8 AphrontApplicationConfiguration::handleThrowable(RuntimeException) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:296]
  #9 AphrontApplicationConfiguration::processRequest(AphrontRequest, PhutilDeferredLog, AphrontPHPHTTPSink, MultimeterControl) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:203]
  #10 AphrontApplicationConfiguration::runHTTPRequest(AphrontPHPHTTPSink) called at [<phorge>/webroot/index.php:35]

After fixing that, "Browse Projects" overlay dialog with search field and list of projects gets rendered in web browser.

(Note to myself: This is a different place than T15335)