gitbutlerapp/gitbutler · error
Commit was marked as not conflictable, but resulted in a…
Error message
Commit {} was marked as not conflictable, but resulted in a conflicted state What it means
Each pick in the rebase plan carries a `conflictable` flag declaring whether it may produce conflicts. After cherry-picking, the outcome was a ConflictedCommit even though the pick was marked non-conflictable. The library refuses to continue because the caller's declaration was violated, preventing silently mishandled conflict state.
Solutions
- Mark the offending commit as conflictable: true so the rebase can surface the conflict properly.
- Resolve the conflict upstream: rebase the commit onto its new base manually, then retry the rebase.
- Check why the commit was marked non-conflictable (e.g. GitButler UI state) and refresh the workspace state.
Example fix
// before
Pick { id, conflictable: false, .. }
// after
Pick { id, conflictable: true, .. } Defensive patterns
Strategy: try-catch
Validate before calling
// Only mark picks non-conflictable when content provably touches disjoint files let safe = pick_files.iter().all(|f| !upstream_changed.contains(f));
Type guard
if let CherryPickOutcome::ConflictedCommit(_) = outcome { /* handle conflict path explicitly */ } Try / catch
match rebase_result {
Err(e) if e.to_string().contains("marked as not conflictable") => {
// retry with conflictable: true for the failing commit
}
other => other?,
} Prevention
- Default conflictable to true unless you can prove disjoint changes
- Refresh conflictable flags after any external branch mutation
- Re-derive flags from actual file overlap instead of caching them
When it happens
Trigger: Invoking rebase with a step whose Pick.conflictable is false, while the underlying git cherry-pick produces CherryPickOutcome::ConflictedCommit — usually because the commit's content actually conflicts with its new parent.
Common situations: Callers marking restore-style or auto-generated commits as non-conflictable when upstream changes make them conflict; stale conflictable flags after branches were rebased or edited externally.
Related errors
- Failed to merge bases while cherry picking commit
- An edge with desired order
- Failed to merge bases while cherry picking commit
- A 'but' binary already exists at
- A matching parent can't be found in the output graph
AI-assisted analysis of gitbutlerapp/gitbutler@58e5313667 (2026-09-18).
Data as JSON: /api/errors/caf363e38b6ba729.
Report an issue: GitHub.
Appendix: source
Thrown at crates/but-rebase/src/graph_rebase/rebase.rs:71
_ => bail!("A parent in the output graph is not a pick"),
}
})
.collect::<Result<Vec<_>>>()?,
};
let outcome = cherry_pick(
&self.repo,
pick.id,
&ontos,
pick.pick_mode,
pick.tree_merge_mode,
pick.sign_commit,
)?;
if matches!(outcome, CherryPickOutcome::ConflictedCommit(_))
&& !pick.conflictable
{
bail!(
"Commit {} was marked as not conflictable, but resulted in a conflicted state",
pick.id
);
}
match outcome {
CherryPickOutcome::Commit(new_id)
| CherryPickOutcome::ConflictedCommit(new_id)
| CherryPickOutcome::Identity(new_id) => {
let mut new_pick = pick.clone();
new_pick.id = new_id;
let new_idx = output_graph.add_node(Step::Pick(new_pick));
graph_mapping.insert(step_idx, new_idx);
if !pick.exclude_from_tracking {
history.update_mapping(pick.id, new_id);
}
new_idxView on GitHub (pinned to 58e5313667)