From 1f28f7d432b66978c9a9adffd6a227a88cae646c Mon Sep 17 00:00:00 2001 From: Takashi Matsubara Date: Thu, 14 Jul 2022 13:58:21 +0900 Subject: [PATCH] fix import Callable for Python3.10 --- django_xmlrpc/registry.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/django_xmlrpc/registry.py b/django_xmlrpc/registry.py index eed1cfb..9795ce9 100644 --- a/django_xmlrpc/registry.py +++ b/django_xmlrpc/registry.py @@ -37,7 +37,12 @@ NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. """ -from collections import Callable +import sys + +if sys.version_info[0:2] >= (3, 10): + from collections.abc import Callable +else: + from collections import Callable from logging import getLogger from django.apps import apps