nikivdev/code · error
Commit queue is empty.
Error message
Commit queue is empty.
What it means
open_latest_queue_review() refreshes and loads the commit queue, and throws this error when there are zero queued entries — there is no latest queued commit to open a review for. It is an empty-state guard before popping the last entry.
Source
Thrown at src/commit.rs:7357
.status();
match status {
Ok(status) => {
if !status.success() {
println!("⚠ Failed to open review (exit {}).", status);
}
}
Err(err) => println!("⚠ Failed to run review opener: {}", err),
}
}
pub fn open_latest_queue_review() -> Result<()> {
ensure_git_repo()?;
let repo_root = git_root_or_cwd();
let _ = refresh_commit_queue(&repo_root);
let mut entries = load_commit_queue_entries(&repo_root)?;
if entries.is_empty() {
bail!("Commit queue is empty.");
}
let entry = entries.pop().unwrap();
println!(
"Opening latest queued commit {} in Rise...",
short_sha(&entry.commit_sha)
);
open_review_in_rise(&repo_root, &entry.commit_sha);
Ok(())
}
fn latest_review_report_for_commit(repo_root: &Path, commit_sha: &str) -> Option<PathBuf> {
let report_dir = flow_commit_reports_dir()?;
let sha_short = short_sha(commit_sha);
let project_slug = safe_label_value(&flow_project_name(repo_root));
let branch = git_capture_in(repo_root, &["rev-parse", "--abbrev-ref", "HEAD"])
.unwrap_or_else(|_| "unknown".to_string())
.trim()
.to_string();View on GitHub (pinned to a747e741ae)
Solutions
- Queue commits first (run the commit/queue flow so entries are recorded)
- If the queue should not be empty, check the internal .ai queue state file still exists
- Re-run the tool from the correct repository root where the queue lives
Example fix
// before (shell) f commit open-review # queue empty // after (shell) f commit # creates queued entries f commit open-review
Defensive patterns
Strategy: validation
Validate before calling
let entries = load_commit_queue_entries(&repo_root)?;
if entries.is_empty() {
eprintln!("queue empty: run the commit flow first");
} else {
open_latest_queue_review()?;
} Try / catch
if let Err(e) = tool.open_latest_queue_review() {
if e.to_string().contains("Commit queue is empty") {
eprintln!("nothing queued yet; create commits first");
} else { return Err(e.into()); }
} Prevention
- Check queue state before invoking review-open commands
- Ensure the commit flow ran at least once in this repo
- Don't delete the internal .ai queue state file
- Run from the repo root so the right queue is loaded
When it happens
Trigger: Calling open_latest_queue_review() (the 'open latest review in Rise' flow) when the commit queue file contains no entries — nothing was ever queued, or the queue was drained by approvals.
Common situations: Running the review-open command before creating any queued commits, after approving/clearing all entries, or after the internal queue state file was deleted or reset by policy fix.
Related errors
- No PR found for current branch and commit queue is empty.
- No branches available to search
- No branches available for AI matching
- No queued commit matches {}
- Multiple queued commits match {}. Use a longer hash.
AI-assisted analysis of nikivdev/code@a747e741ae (2026-09-01).
Data as JSON: /api/errors/df0f71faf78ee1af.
Report an issue: GitHub.