status: explicitly exclude removed file from unknown and ignored
Changeset
64fe488b5179 introduced a test to validate that file were not reported
twice when both unknown and removed. This behavior change was introduced by
65cdc6bab91e alongside a bug that dropped ignored and unknown completely
(
issue4321). As we are going to fix the bug, we need a proper implementation of
the behavior tested in
64fe488b5179.
--- a/mercurial/context.py Fri Aug 01 11:45:26 2014 -0500
+++ b/mercurial/context.py Fri Aug 01 13:13:24 2014 -0700
@@ -135,6 +135,10 @@
elif fn not in deleted:
added.append(fn)
removed = mf1.keys()
+ if removed:
+ # need to filter files if they are already reported as removed
+ unknown = [fn for fn in unknown if fn not in mf1]
+ ignored = [fn for fn in ignored if fn not in mf1]
return [modified, added, removed, deleted, unknown, ignored, clean]