Page MenuHomePhorge

PHP 8.1 "addcslashes(null)" exception exporting task list to tab-separated text
Closed, ResolvedPublic

Description

  1. PHP 8.2.17; Phorge at d4af32c1d4120a5804e3d8c4b9d9c37476aa272e
  2. Have some Maniphest tasks assigned to yourself
  3. Go to http://phorge.localhost/maniphest/query/assigned/
  4. Select Use Results > Export Data
  5. Select Format = Tab-Separated Text and click Download Data button
[2024-04-02 20:33:06] ERROR 8192: addcslashes(): Passing null to parameter #1 ($string) of type string is deprecated at [/var/www/html/phorge/phorge/src/infrastructure/export/format/PhabricatorTextExportFormat.php:45]
arcanist(head=master, ref.master=ef73b12b580e), phorge(head=csvExport, ref.master=d4af32c1d412, ref.csvExport=51c447743ff1)
  #0 addcslashes(NULL, string) called at [<phorge>/src/infrastructure/export/format/PhabricatorTextExportFormat.php:45]
  #1 PhabricatorTextExportFormat::addRow(array) called at [<phorge>/src/infrastructure/export/format/PhabricatorTextExportFormat.php:39]
  #2 PhabricatorTextExportFormat::addObject(ManiphestTask, array, array) called at [<phorge>/src/infrastructure/export/engine/PhabricatorExportEngine.php:146]
  #3 PhabricatorExportEngine::exportFile() called at [<phorge>/src/applications/search/controller/PhabricatorApplicationSearchController.php:520]
  #4 PhabricatorApplicationSearchController::processExportRequest() called at [<phorge>/src/applications/search/controller/PhabricatorApplicationSearchController.php:80]
  #5 PhabricatorApplicationSearchController::processRequest() called at [<phorge>/src/aphront/AphrontController.php:29]
  #6 AphrontController::handleRequest(AphrontRequest) called at [<phorge>/src/aphront/AphrontController.php:71]
  #7 AphrontController::delegateToController(PhabricatorApplicationSearchController) called at [<phorge>/src/applications/maniphest/controller/ManiphestTaskListController.php:20]
  #8 ManiphestTaskListController::handleRequest(AphrontRequest) called at [<phorge>/src/aphront/configuration/AphrontApplicationConfiguration.php:284]
  #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]

repeated for every task.