From 6e2e0bd67ac75ef96de41eac806ec1b980505c54 Mon Sep 17 00:00:00 2001 From: "Gerber, Mike" Date: Thu, 5 May 2022 11:10:59 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Fix=20imports?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- qurator/modstool/lib.py | 1 + qurator/modstool/modstool.py | 2 +- qurator/modstool/tests/test_mets.py | 3 ++- qurator/modstool/tests/test_modstool.py | 4 +++- 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/qurator/modstool/lib.py b/qurator/modstool/lib.py index c22689e..b24b698 100644 --- a/qurator/modstool/lib.py +++ b/qurator/modstool/lib.py @@ -162,6 +162,7 @@ class TagGroup: return self def merge_sub_tags_to_set(self): + from .modstool import mods_to_dict value = {} sub_dicts = [mods_to_dict(e) for e in self.group] diff --git a/qurator/modstool/modstool.py b/qurator/modstool/modstool.py index bc7429b..a6fe164 100755 --- a/qurator/modstool/modstool.py +++ b/qurator/modstool/modstool.py @@ -14,7 +14,7 @@ import click import pandas as pd from tqdm import tqdm -from .lib import sorted_groupby, TagGroup, ns +from .lib import sorted_groupby, TagGroup, ns, flatten diff --git a/qurator/modstool/tests/test_mets.py b/qurator/modstool/tests/test_mets.py index 76aa73f..315c7b6 100644 --- a/qurator/modstool/tests/test_mets.py +++ b/qurator/modstool/tests/test_mets.py @@ -1,7 +1,8 @@ import xml.etree.ElementTree as ET -from .. import mets_to_dict, flatten +from qurator.modstool.modstool import mets_to_dict +from qurator.modstool.lib import flatten def dict_fromstring(x): diff --git a/qurator/modstool/tests/test_modstool.py b/qurator/modstool/tests/test_modstool.py index b13586a..c31e3e8 100644 --- a/qurator/modstool/tests/test_modstool.py +++ b/qurator/modstool/tests/test_modstool.py @@ -1,8 +1,10 @@ +from tkinter import W import pytest import xml.etree.ElementTree as ET -from .. import mods_to_dict, flatten +from qurator.modstool.modstool import mods_to_dict +from qurator.modstool.lib import flatten def dict_fromstring(x):