From 018afefee6fa18f014e68f762cdcd63e7d050a7f Mon Sep 17 00:00:00 2001 From: Shay Carter Date: Wed, 23 Aug 2023 12:41:20 -0600 Subject: [PATCH] More modifications to the source v20 python code - DataAccessLayer will have more changes to come to re-incorporate MJs changes, but for now, change the THRIFT_HOST to "edex" - EnumSet has to use collections.abc import instead of collections to be compatible with newer versions of python (3.10) --- awips/dataaccess/DataAccessLayer.py | 5 +---- dynamicserialize/dstypes/java/util/EnumSet.py | 4 ++-- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/awips/dataaccess/DataAccessLayer.py b/awips/dataaccess/DataAccessLayer.py index e768a87..6899cb9 100644 --- a/awips/dataaccess/DataAccessLayer.py +++ b/awips/dataaccess/DataAccessLayer.py @@ -49,10 +49,7 @@ import sys import subprocess import warnings -THRIFT_HOST = subprocess.check_output( - "source /awips2/fxa/bin/setup.env; echo $DEFAULT_HOST", - shell=True).decode().strip() - +THRIFT_HOST = "edex" USING_NATIVE_THRIFT = False diff --git a/dynamicserialize/dstypes/java/util/EnumSet.py b/dynamicserialize/dstypes/java/util/EnumSet.py index e6af671..44b8a60 100644 --- a/dynamicserialize/dstypes/java/util/EnumSet.py +++ b/dynamicserialize/dstypes/java/util/EnumSet.py @@ -37,10 +37,10 @@ # values to your EnumSet. ## -import collections +import collections.abc -class EnumSet(collections.MutableSet): +class EnumSet(collections.abc.MutableSet): def __init__(self, enumClassName, iterable=[]): self.__enumClassName = enumClassName