phacility/phabricator · error · PhutilArgumentUsageException

No log records exist for any daemons.

Error message

No log records exist for any daemons.

What it means

Fires when no --id filter was given and the daemon log query returned no rows at all: there are no daemon log records in the database to display. This is an empty-result guard on PhabricatorDaemonLogQuery, not an argument error.

Solutions

  1. Start daemons with phd start so log records are produced
  2. Check that the phd log directory/database is intact and logs were not pruned
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at src/applications/daemon/management/PhabricatorDaemonManagementLogWorkflow.php:55 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of phacility/phabricator@5720a38cfe (2026-08-21). Data as JSON: /api/errors/dc7d94ef425bd4e7. Report an issue: GitHub.

Appendix: source

Thrown at src/applications/daemon/management/PhabricatorDaemonManagementLogWorkflow.php:55

      ->setAllowStatusWrites(true);
    $ids = $args->getArg('id');
    if ($ids) {
      $query->withIDs($ids);
    }
    $daemons = $query->execute();
    $daemons = mpull($daemons, null, 'getID');

    if ($ids) {
      foreach ($ids as $id) {
        if (!isset($daemons[$id])) {
          throw new PhutilArgumentUsageException(
            pht(
              'No log record exists for a daemon with ID "%s".',
              $id));
        }
      }
    } else if (!$daemons) {
      throw new PhutilArgumentUsageException(
        pht('No log records exist for any daemons.'));
    }

    $console = PhutilConsole::getConsole();

    $limit = $args->getArg('limit');

    $logs = id(new PhabricatorDaemonLogEvent())->loadAllWhere(
      'logID IN (%Ld) ORDER BY id DESC LIMIT %d',
      mpull($daemons, 'getID'),
      $limit);
    $logs = array_reverse($logs);

    $lines = array();
    foreach ($logs as $log) {
      $text_lines = phutil_split_lines($log->getMessage(), $retain = false);
      foreach ($text_lines as $line) {
        $lines[] = array(

View on GitHub (pinned to 5720a38cfe)