repo:recover-departed

Clone the repository that now holds a departed node and replay the selected source checkout's unpublished commits there. If interrupted, check the source checkout with repo:status: if its departure rebase is still paused, delete the destination checkout and run recovery again, and never reuse or push it; if the rebase is finished, keep the destination checkout, which holds the recovered work.

Reference for flywheel repo:recover-departed.

HTTP 426 prints http_error, with client_version_unsupported or repository_snapshot_format_unsupported in server_response.body.detail (or its type field). Update Flywheel and retry. The source may already have been pulled before the destination clone is refused; no destination checkout was created.

If a hosted request fails before the destination checkout exists (the connection is refused or drops, the request times out, the answer can't be read, or HTTP 408, 429, 502, 503 or 504 is still the answer after the CLI's retries), the error keeps its code and adds step, either source_pull (pulling the hosted changes into the source checkout, which recovery does first when the source does not know about the departure yet) or destination_clone (cloning the repository that now holds the departed node), and next_action, the same command as typed, with the same arguments. Recovery has no --idempotency-key, so the rerun has none; run next_action once the hosted service can be reached again. A hosted repository_busy answer gets a step and this next_action too, and keeps its code repository_busy. A failure after the destination clone exists is reported with that checkout instead, and its message says whether to keep it.

Command Group

Local Repository

Summary

Clone the repository that now holds a departed node and replay the selected source checkout's unpublished commits there. If interrupted, check the source checkout with repo:status: if its departure rebase is still paused, delete the destination checkout and run recovery again, and never reuse or push it; if the rebase is finished, keep the destination checkout, which holds the recovered work.

Usage

flywheel repo:recover-departed [FLAGS] <current_repository_id> <directory>

Arguments

ArgumentRequiredChoicesDescription
<current_repository_id>YesRepository UUID that now holds the departed node.
<directory>YesTarget repository directory.

Required flags

None.

Optional flags

FlagValueDefaultChoicesDescription
--repostringLocal repository filesystem path.
--personalUse the configured personal repository.
--formatFORMATjson, tsv, csv, tableOutput format for command results.
--envPROFILEUse a configured CLI profile for this invocation.
--outPATHWrite output to a file path, or use - for stdout.
--openOpen browser-bound URLs when supported.
--no-retryDisable transient-error retries.
--retry-maxNMaximum transient-error retry attempts.
--waitBlock on async operations until a terminal state is reached.
--wait-timeoutSECONDS600Seconds to wait for --wait before timing out. Defaults to 600.
--allow-selfAllow mutating the currently active credential.
--timeoutSECONDSSet the per-request timeout budget in seconds.
--idempotency-keyKEYReuse an Idempotency-Key so ambiguous write failures can be retried with the same key.
--forceForce safety-gated operations where supported.
--yesSkip confirmation prompts for destructive operations.
--debugPrint structured request debugging with secrets masked.
--verbosePrint verbose progress for long-running operations.
-h, --helpShow this help.

Examples

Recover a refused departed-node write in one client-side follow-up; the original hosted write is never redirected.

flywheel repo:recover-departed <current_repository_id> <directory> --repo <path>