Skip to content

Commit dc18110

Browse files
committed
fix encoding for ipy
1 parent 3983110 commit dc18110

File tree

1 file changed

+13
-14
lines changed

1 file changed

+13
-14
lines changed

src/compas/datastructures/tree/hashtree.py

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# -*- coding: utf-8 -*-
12
import hashlib
23

34
from compas.data import Data
@@ -117,21 +118,19 @@ class HashTree(Tree):
117118
>>> tree1 = HashTree.from_dict({"a": {"b": 1, "c": 3}, "d": [1, 2, 3], "e": 2})
118119
>>> tree2 = HashTree.from_dict({"a": {"b": 1, "c": 2}, "d": [1, 2, 3], "f": 2})
119120
>>> print(tree1)
120-
<Tree with 6 nodes>
121-
└── ROOT @ 4cd56
122-
├── .a @ c16fd
123-
│ ├── .b:1 @ c9b55
124-
│ └── .c:3 @ 518d4
125-
├── .d:[1, 2, 3] @ 9be3a
126-
└── .e:2 @ 68355
121+
+-- ROOT @ 4cd56
122+
+-- .a @ c16fd
123+
| +-- .b:1 @ c9b55
124+
| +-- .c:3 @ 518d4
125+
+-- .d:[1, 2, 3] @ 9be3a
126+
+-- .e:2 @ 68355
127127
>>> print(tree2)
128-
<Tree with 6 nodes>
129-
└── ROOT @ fbe39
130-
├── .a @ c2022
131-
│ ├── .b:1 @ c9b55
132-
│ └── .c:2 @ e3365
133-
├── .d:[1, 2, 3] @ 9be3a
134-
└── .f:2 @ 93861
128+
+-- ROOT @ fbe39
129+
+-- .a @ c2022
130+
| +-- .b:1 @ c9b55
131+
| +-- .c:2 @ e3365
132+
+-- .d:[1, 2, 3] @ 9be3a
133+
+-- .f:2 @ 93861
135134
>>> tree2.print_diff(tree1)
136135
Added:
137136
{'path': '.f', 'value': 2}

0 commit comments

Comments
 (0)