Skip to content

Commit

Permalink
Update to the most recent versions of the submodules.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaeadams committed Nov 2, 2022
1 parent 8653726 commit 59a9afa
Show file tree
Hide file tree
Showing 7 changed files with 47 additions and 51 deletions.
54 changes: 23 additions & 31 deletions g2/python/G2ConfigTool.py
Original file line number Diff line number Diff line change
Expand Up @@ -4089,53 +4089,45 @@ def do_templateAdd(self, arg):

validTemplates = {}

validTemplates['GLOBAL_ID'] = {
'DESCRIPTION': 'globally unique identifier (like an ssn, a credit card, or a medicare_id)',
'BEHAVIOR': ['F1', 'F1E', 'F1ES'],
'CANDIDATES': ['No'],
'STANDARDIZE': ['PARSE_ID'],
'EXPRESSION': ['EXPRESS_ID'],
'COMPARISON': ['ID_COMP', 'EXACT_COMP'],
'FEATURE_CLASS': 'ISSUED_ID',
'ATTRIBUTE_CLASS': 'IDENTIFIER',
'ELEMENTS': [{'element': 'ID_NUM', 'expressed': 'No', 'compared': 'no', 'display': 'Yes'},
{'element': 'ID_NUM_STD', 'expressed': 'Yes', 'compared': 'yes', 'display': 'No'}],
'ATTRIBUTES': [{'attribute': '<feature>', 'element': 'ID_NUM', 'required': 'Yes'}]}
validTemplates['GLOBAL_ID'] = {'DESCRIPTION': 'globally unique identifier (like an ssn, a credit card, or a medicare_id)',
'BEHAVIOR': ['F1', 'F1E', 'F1ES', 'A1', 'A1E', 'A1ES'],
'CANDIDATES': ['No'],
'STANDARDIZE': ['PARSE_ID'],
'EXPRESSION': ['EXPRESS_ID'],
'COMPARISON': ['ID_COMP', 'EXACT_COMP'],
'FEATURE_CLASS': 'ISSUED_ID',
'ATTRIBUTE_CLASS': 'IDENTIFIER',
'ELEMENTS': [{'element': 'ID_NUM', 'expressed': 'No', 'compared': 'no', 'display': 'Yes'},
{'element': 'ID_NUM_STD', 'expressed': 'Yes', 'compared': 'yes', 'display': 'No'}],
'ATTRIBUTES': [{'attribute': '<feature>', 'element': 'ID_NUM', 'required': 'Yes'}]}

validTemplates['STATE_ID'] = {'DESCRIPTION': 'state issued identifier (like a drivers license)',
'BEHAVIOR': ['F1', 'F1E', 'F1ES'],
'BEHAVIOR': ['F1', 'F1E', 'F1ES', 'A1', 'A1E', 'A1ES'],
'CANDIDATES': ['No'],
'STANDARDIZE': ['PARSE_ID'],
'EXPRESSION': ['EXPRESS_ID'],
'COMPARISON': ['ID_COMP'],
'FEATURE_CLASS': 'ISSUED_ID',
'ATTRIBUTE_CLASS': 'IDENTIFIER',
'ELEMENTS': [
{'element': 'ID_NUM', 'expressed': 'No', 'compared': 'no', 'display': 'Yes'},
{'element': 'STATE', 'expressed': 'No', 'compared': 'yes', 'display': 'Yes'},
{'element': 'ID_NUM_STD', 'expressed': 'Yes', 'compared': 'yes',
'display': 'No'}],
'ATTRIBUTES': [
{'attribute': '<feature>_NUMBER', 'element': 'ID_NUM', 'required': 'Yes'},
{'attribute': '<feature>_STATE', 'element': 'STATE', 'required': 'No'}]}
'ELEMENTS': [{'element': 'ID_NUM', 'expressed': 'No', 'compared': 'no', 'display': 'Yes'},
{'element': 'STATE', 'expressed': 'No', 'compared': 'yes', 'display': 'Yes'},
{'element': 'ID_NUM_STD', 'expressed': 'Yes', 'compared': 'yes', 'display': 'No'}],
'ATTRIBUTES': [{'attribute': '<feature>_NUMBER', 'element': 'ID_NUM', 'required': 'Yes'},
{'attribute': '<feature>_STATE', 'element': 'STATE', 'required': 'No'}]}

validTemplates['COUNTRY_ID'] = {'DESCRIPTION': 'country issued identifier (like a passport)',
'BEHAVIOR': ['F1', 'F1E', 'F1ES'],
'BEHAVIOR': ['F1', 'F1E', 'F1ES', 'A1', 'A1E', 'A1ES'],
'CANDIDATES': ['No'],
'STANDARDIZE': ['PARSE_ID'],
'EXPRESSION': ['EXPRESS_ID'],
'COMPARISON': ['ID_COMP'],
'FEATURE_CLASS': 'ISSUED_ID',
'ATTRIBUTE_CLASS': 'IDENTIFIER',
'ELEMENTS': [{'element': 'ID_NUM', 'expressed': 'No', 'compared': 'no',
'display': 'Yes'},
{'element': 'COUNTRY', 'expressed': 'No', 'compared': 'yes',
'display': 'Yes'},
{'element': 'ID_NUM_STD', 'expressed': 'Yes', 'compared': 'yes',
'display': 'No'}],
'ATTRIBUTES': [
{'attribute': '<feature>_NUMBER', 'element': 'ID_NUM', 'required': 'Yes'},
{'attribute': '<feature>_COUNTRY', 'element': 'COUNTRY', 'required': 'No'}]}
'ELEMENTS': [{'element': 'ID_NUM', 'expressed': 'No', 'compared': 'no', 'display': 'Yes'},
{'element': 'COUNTRY', 'expressed': 'No', 'compared': 'yes', 'display': 'Yes'},
{'element': 'ID_NUM_STD', 'expressed': 'Yes', 'compared': 'yes', 'display': 'No'}],
'ATTRIBUTES': [{'attribute': '<feature>_NUMBER', 'element': 'ID_NUM', 'required': 'Yes'},
{'attribute': '<feature>_COUNTRY', 'element': 'COUNTRY', 'required': 'No'}]}

if arg and arg.upper() == 'LIST':
print()
Expand Down
4 changes: 2 additions & 2 deletions g2/python/G2Loader.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@
from senzing import G2Config, G2ConfigMgr, G2Diagnostic, G2Engine, G2Exception, G2Product, G2ModuleLicenseException

__all__ = []
__version__ = '2.2.0' # See https://www.python.org/dev/peps/pep-0396/
__version__ = '2.2.2' # See https://www.python.org/dev/peps/pep-0396/
__date__ = '2018-09-18'
__updated__ = '2022-08-26'
__updated__ = '2022-10-11'

# -----------------------------------------------------------------------------
# Exceptions
Expand Down
32 changes: 18 additions & 14 deletions g2/python/G2Paths.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,24 @@

# The Senzing python tools call G2Paths before starting engine to locate the engine configuration. Error if can't locate
# a G2Module.ini or SENZING_ENGINE_CONFIGURATION_JSON
if 'SENZING_ETC_PATH' not in os.environ and 'SENZING_ROOT' not in os.environ and 'SENZING_ENGINE_CONFIGURATION_JSON' not in os.environ:

print(textwrap.dedent('''\n\
ERROR: SENZING_ROOT or SENZING_ENGINE_CONFIGURATION_JSON environment variable is not set:
- If using a Senzing project on a bare metal install, source the setupEnv file in the project root path.
https://senzing.zendesk.com/hc/en-us/articles/115002408867-Introduction-G2-Quickstart
- If running within a container set the SENZING_ENGINE_CONFIGURATION_JSON environment variable.
https://github.com/Senzing/knowledge-base/blob/main/lists/environment-variables.md#senzing_engine_configuration_json
'''))
sys.exit(1)
if 'SENZING_ETC_PATH' not in os.environ and 'SENZING_ROOT' not in os.environ:

# Check if set or not and that it's not set to null
secj = os.environ.get('SENZING_ENGINE_CONFIGURATION_JSON')
if not secj or (secj and len(secj) == 0):

print(textwrap.dedent('''\n\
ERROR: SENZING_ROOT or SENZING_ENGINE_CONFIGURATION_JSON environment variable is not set:
- If using a Senzing project on a bare metal install, source the setupEnv file in the project root path.
https://senzing.zendesk.com/hc/en-us/articles/115002408867-Introduction-G2-Quickstart
- If running within a container set the SENZING_ENGINE_CONFIGURATION_JSON environment variable.
https://github.com/Senzing/knowledge-base/blob/main/lists/environment-variables.md#senzing_engine_configuration_json
'''))
sys.exit(1)

# Search paths checked for INI file requested. Path can be for a local Senzing project
# (created with G2CreateProject.py) or a 'system install' path - for example using an
Expand Down
2 changes: 1 addition & 1 deletion g2command
2 changes: 1 addition & 1 deletion g2configtool
2 changes: 1 addition & 1 deletion g2loader
2 changes: 1 addition & 1 deletion g2paths

0 comments on commit 59a9afa

Please sign in to comment.