phacility/phabricator · warning · Exception
Declining to apply changes.
Error message
Declining to apply changes.
What it means
Thrown by `bin/repository move-paths` after it draws the table of proposed `localPath` rewrites: `phutil_console_confirm('Apply these changes?')` returned false — the operator answered 'n' at the prompt (or input was non-affirmative). It is an intentional abort before the `UPDATE %T SET localPath = ...` writes, so no repository rows were modified.
Source
Thrown at src/applications/repository/management/PhabricatorRepositoryManagementMovePathsWorkflow.php:128
array(
'action',
'monogram',
'src',
'dst',
));
$table->addRow($display);
}
$table->draw();
if (!$any_changes) {
$console->writeOut(pht('No matching repositories.')."\n");
return 0;
}
$prompt = pht('Apply these changes?');
if (!$is_force && !phutil_console_confirm($prompt)) {
throw new Exception(pht('Declining to apply changes.'));
}
foreach ($rows as $row) {
if (empty($row['move'])) {
continue;
}
$repo = $row['repository'];
queryfx(
$repo->establishConnection('w'),
'UPDATE %T SET localPath = %s WHERE id = %d',
$repo->getTableName(),
$row['dst'],
$repo->getID());
}
$console->writeOut(pht('Applied changes.')."\n");View on GitHub (pinned to 5720a38cfe)
Solutions
- Fix whatever looked wrong in the preview table (--from/--to prefixes) and re-run, answering 'y'.
- For unattended runs, pass `--force` to skip the prompt — only after verifying the prefixes.
- If nothing needed changing, this abort is the correct outcome — verify with the 'No matching repositories.' path.
Example fix
// before $ ./bin/repository move-paths --from /var/repos --to /srv/repos Apply these changes? [y/N] n [1179] Declining to apply changes. // after $ ./bin/repository move-paths --from /var/repos --to /srv/repos --force # unattended, prefixes verified
Defensive patterns
Strategy: validation
Validate before calling
# Unattended/verified run: skip the interactive prompt deliberately ./bin/repository move-paths --from "$FROM" --to "$TO" --force
Prevention
- Treat this exception as a no-op abort: nothing was changed, just re-run with corrected flags.
- Use --force only in unattended scripts after a dry-run review of the preview table.
- Keep runs interactive when prefixes are uncertain so the prompt can catch mistakes.
When it happens
Trigger: Answering 'n' (or anything not starting with y) at the 'Apply these changes?' prompt; running interactively and dismissing the prompt; EOF/non-TTY input that fails to confirm affirmatively.
Common situations: Operators review the preview table, spot a wrong prefix, and decline; automated runs where stdin is not a TTY and confirm defaults to no.
Related errors
- This service is configured to operate in cluster mode, but %
- Expected "\r\n" or "--" after multipart data boundary.
- Failed to read stdin.
- Expected a list of hints in JSON format: %s
- Each item in the list of hints should be a JSON object, but
AI-assisted analysis of phacility/phabricator@5720a38cfe (2026-08-21).
Data as JSON: /api/errors/1603cf83f8e0ad24.
Report an issue: GitHub.