From 885628f5bd457030def9eac5dec9b49dec74159b Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Fri, 3 Jan 2025 21:43:17 +0100 Subject: [PATCH] Update dependencies (2025-01) And fix the new mypy errors by not reusing the `stream` variable for multiple purposes. --- requirements.txt | 6 +++--- tests/test_ged2dot.py | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/requirements.txt b/requirements.txt index b22fc00..99baa54 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,7 +1,7 @@ -coverage==7.6.8 +coverage==7.6.10 flake8==7.1.1 -mypy==1.13.0 +mypy==1.14.1 pygraphviz==1.14 pyinstaller==6.11.1 -pylint==3.3.1 +pylint==3.3.3 pyqt6==6.7.1 diff --git a/tests/test_ged2dot.py b/tests/test_ged2dot.py index 92c5836..3dc881a 100644 --- a/tests/test_ged2dot.py +++ b/tests/test_ged2dot.py @@ -140,8 +140,8 @@ def test_happy(self) -> None: self.assertFalse(os.path.exists(config["output"])) ged2dot.convert(config) self.assertTrue(os.path.exists(config["output"])) - with open(config["output"], "r", encoding="utf-8") as stream: - graph = pygraphviz.AGraph(string=stream.read()) + with open(config["output"], "r", encoding="utf-8") as dot_stream: + graph = pygraphviz.AGraph(string=dot_stream.read()) person = graph.get_node("P48") stream = io.StringIO(person.attr.get("label")) tree = ET.parse(stream) @@ -547,8 +547,8 @@ def test_fam_no_marr(self) -> None: # Then make sure that explicit width and height is specified for the table around the image, # required by the PNG output: - with open(config["output"], "r", encoding="utf-8") as stream: - graph = pygraphviz.AGraph(string=stream.read()) + with open(config["output"], "r", encoding="utf-8") as dot_stream: + graph = pygraphviz.AGraph(string=dot_stream.read()) family = graph.get_node("F1") stream = io.StringIO(family.attr.get("label")) tree = ET.parse(stream)