--- a/hgext3rd/topic/stack.py Sun Sep 08 21:24:45 2019 +0200
+++ b/hgext3rd/topic/stack.py Tue Sep 10 07:38:46 2019 +0200
@@ -143,9 +143,18 @@
# processed dependency graph.
# Step 1: compute relation of revision with each other
- dependencies, rdependencies = self._dependencies
- dependencies = dependencies.copy()
- rdependencies = rdependencies.copy()
+ origdeps, rdependencies = self._dependencies
+ dependencies = {}
+ # Making a deep copy of origdeps because we modify contents of values
+ # later on. Checking for list here only because right now
+ # builddependencies in evolvebits.py can return a list of _succs()
+ # objects. When that will be dealt with, this deep copy code can be
+ # simplified a lot.
+ for k, v in origdeps.items():
+ if isinstance(v, list):
+ dependencies[k] = [i.copy() for i in v]
+ else:
+ dependencies[k] = v.copy()
# Step 2: Build the ordering
# Remove the revisions with no dependency(A) and add them to the ordering.
# Removing these revisions leads to new revisions with no dependency (the