From 24a8e532156ba362b08512518a376fbcbbfffe15 Mon Sep 17 00:00:00 2001 From: rprinz08 Date: Fri, 9 Dec 2022 15:00:45 +0100 Subject: [PATCH] Fix thread import error --- parcon/ordered_dict.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/parcon/ordered_dict.py b/parcon/ordered_dict.py index d5bb6b4..98f986e 100644 --- a/parcon/ordered_dict.py +++ b/parcon/ordered_dict.py @@ -8,12 +8,15 @@ import six try: - from thread import get_ident as _get_ident + from _thread import get_ident as _get_ident except ImportError: try: - from dummy_thread import get_ident as _get_ident + from thread import get_ident as _get_ident except ImportError: - from _dummy_thread import get_ident as _get_ident + try: + from dummy_thread import get_ident as _get_ident + except ImportError: + from _dummy_thread import get_ident as _get_ident try: from _abcoll import KeysView, ValuesView, ItemsView