diff --git a/CHANGELOG.md b/CHANGELOG.md index f05e514e..27c9159f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ ## Release notes +### Upcoming +- Fixed - Added encapsulating double quotes to comply with [DOT language](https://graphviz.org/doc/info/lang.html) - PR [#1176](https://github.com/datajoint/datajoint-python/pull/1176) + ### 0.14.2 -- Aug 19, 2024 - Added - Migrate nosetests to pytest - PR [#1142](https://github.com/datajoint/datajoint-python/pull/1142) - Added - Codespell GitHub Actions workflow diff --git a/datajoint/diagram.py b/datajoint/diagram.py index 65497fcf..0d35a98b 100644 --- a/datajoint/diagram.py +++ b/datajoint/diagram.py @@ -289,7 +289,7 @@ def _make_graph(self): ) # relabel nodes to class names mapping = { - node: lookup_class_name(node, self.context) or node + node: f'"{lookup_class_name(node, self.context) or node}"' for node in graph.nodes() } new_names = [mapping.values()] diff --git a/tests_old/test_erd.py b/tests_old/test_erd.py index 1a629343..a27b6463 100644 --- a/tests_old/test_erd.py +++ b/tests_old/test_erd.py @@ -83,5 +83,5 @@ def test_part_table_parsing(): # https://github.com/datajoint/datajoint-python/issues/882 erd = dj.Di(schema) graph = erd._make_graph() - assert "OutfitLaunch" in graph.nodes() - assert "OutfitLaunch.OutfitPiece" in graph.nodes() + assert '"OutfitLaunch"' in graph.nodes() + assert '"OutfitLaunch.OutfitPiece"' in graph.nodes()