phacility/phabricator · error · PhabricatorWorkerPermanentFailureException

File " " does not exist.

Error message

File "%s" does not exist.

What it means

Permanent task failure in the file deletion worker: the objectPHID in the task data names no existing file (deleted independently or never created), so the queue task can never succeed and is discarded permanently.

Solutions

  1. No action needed if the file was already deleted — the task is intentionally permanent-failed
  2. Verify no code path enqueues deletion tasks for unsaved files
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at src/applications/files/worker/FileDeletionWorker.php:18 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/ac5fa73cc733d22e. Report an issue: GitHub.

Appendix: source

Thrown at src/applications/files/worker/FileDeletionWorker.php:18

<?php

final class FileDeletionWorker extends PhabricatorWorker {

  private function loadFile() {
    $phid = idx($this->getTaskData(), 'objectPHID');
    if (!$phid) {
      throw new PhabricatorWorkerPermanentFailureException(
        pht('No "%s" in task data.', 'objectPHID'));
    }

    $file = id(new PhabricatorFileQuery())
      ->setViewer(PhabricatorUser::getOmnipotentUser())
      ->withPHIDs(array($phid))
      ->executeOne();

    if (!$file) {
      throw new PhabricatorWorkerPermanentFailureException(
        pht('File "%s" does not exist.', $phid));
    }

    return $file;
  }

  protected function doWork() {
    $file = $this->loadFile();
    $engine = new PhabricatorDestructionEngine();
    $engine->destroyObject($file);
  }

}

View on GitHub (pinned to 5720a38cfe)