filter-repo: fix --prune-degenerate=never with path filtering
When combining `--prune-degenerate never` with a `--path` specification, we could end up trying to write a parent out to the fast-import stream whose value was actually None. The problem occurs when the parents of a merge commit are filtered out by the path specification, leaving us only with no-longer-extant parents. In such a case, we need to filter out these 'None' (i.e. invalid) parents. The point of `--prune-degenerate never` is to avoid removing parents that are either the same as or an ancestor of another parent, not to avoid removing non-existent parents. Remove the non-existent parent(s). Reported-by: Gaurav Kanoongo (@gauravkanoongo on GitHub) Signed-off-by: Elijah Newren <newren@gmail.com>pull/101/head
parent
df6c8652a2
commit
7b18e6d7f5
Loading…
Reference in New Issue