Scratch the last comment. The code actually uses the getattr() check to decide that it *does* need to use _iter_parent_trees. Which means that the try/catch is always wrong.
I'll also note that it is doing:
tree.inventory[file_id].revision for tree in self._iter_parent_trees()
which means that if the file is deleted in one of the merge parents, it will raise the NoSuchId error. I haven't been able to put together a simple test case yet, but it looks like I've at least isolated the portion of code.
Scratch the last comment. The code actually uses the getattr() check to decide that it *does* need to use _iter_parent_trees. Which means that the try/catch is always wrong.
I'll also note that it is doing:
tree. inventory[ file_id] .revision for tree in self._iter_ parent_ trees()
which means that if the file is deleted in one of the merge parents, it will raise the NoSuchId error. I haven't been able to put together a simple test case yet, but it looks like I've at least isolated the portion of code.