Repository: hed-standard/hed-python (language: python)

Issue:
Web work
Clarified documentation on the home page.


Discussion / hints:

Fix patch:
diff --git a/webtools/hedweb/dictionary.py b/webtools/hedweb/dictionary.py
index 722a4b5bd..c197069b1 100644
--- a/webtools/hedweb/dictionary.py
+++ b/webtools/hedweb/dictionary.py
@@ -1,3 +1,4 @@
+import io
 from flask import current_app
 from werkzeug.utils import secure_filename
 
@@ -29,9 +30,8 @@ def get_input_from_dictionary_form(request):
                  common.CHECK_FOR_WARNINGS: form_has_option(request, common.CHECK_FOR_WARNINGS, 'on')}
     if common.JSON_FILE in request.files:
         f = request.files[common.JSON_FILE]
-        arguments[common.JSON_DICTIONARY] = \
-            models.ColumnDefGroup(json_string=f.read(file_constants.BYTE_LIMIT).decode('ascii'),
-                                  display_name=secure_filename(f.filename))
+        fb = io.StringIO(f.read(file_constants.BYTE_LIMIT).decode('ascii'))
+        arguments[common.JSON_DICTIONARY] = models.ColumnDefGroup(file=fb, name=secure_filename(f.filename))
     return arguments
 
 
@@ -105,7 +105,7 @@ def dictionary_convert(hed_schema, json_dictionary, command=common.COMMAND_TO_LO
             column_def.set_hed_string(converted_string, position)
 
     # issues = ErrorHandler.filter_issues_by_severity(issues, ErrorSeverity.ERROR)
-    display_name = json_dictionary.display_name
+    display_name = json_dictionary.name
     if issues:
         issue_str = get_printable_issue_string(issues, f"JSON conversion for {display_name} was unsuccessful")
         file_name = generate_filename(display_name, suffix=f"{suffix}_conversion_errors", extension='.txt')
@@ -139,15 +139,15 @@ def dictionary_validate(hed_schema, json_dictionary):
     schema_version = hed_schema.header_attributes.get('version', 'Unknown version')
     if not json_dictionary or not isinstance(json_dictionary, models.ColumnDefGroup):
         raise HedFileError('BadDictionaryFile', "Please provide a dictionary to process", "")
-    display_name = json_dictionary.display_name
-    def_dict = json_dictionary.extract_defs()
-    issues = def_dict.get_def_issues(hed_schema)
-    if issues:
-        issue_str = get_printable_issue_string(issues, f"JSON dictionary {display_name} definition errors")
-        file_name = generate_filename(display_name, suffix='_dictionary_errors', extension='.txt')
-        return {common.COMMAND: common.COMMAND_VALIDATE, 'data': issue_str, 'output_display_name': file_name,
-                common.SCHEMA_VERSION: schema_version, 'msg_category': 'warning',
-                'msg': f"JSON dictionary {display_name} had definition errors"}
+    display_name = json_dictionary.name
+    # def_dict = json_dictionary.extract_defs()
+    # issues = def_dict.get_def_issues(hed_schema)
+    # if issues:
+    #     issue_str = get_printable_issue_string(issues, f"JSON dictionary {display_name} definition errors")
+    #     file_name = generate_filename(display_name, suffix='_dictionary_errors', extension='.txt')
+    #     return {common.COMMAND: common.COMMAND_VALIDATE, 'data': issue_str, 'output_display_name': file_name,
+    #             common.SCHEMA_VERSION: schema_version, 'msg_category': 'warning',
+    #             'msg': f"JSON dictionary {display_name} had definition errors"}
 
     issues = json_dictionary.validate_entries(hed_schema)
     if issues:
diff --git a/webtools/hedweb/events.py b/webtools/hedweb/events.py
index ffd85ef75..0b89d0705 100644
--- a/webtools/hedweb/events.py
+++ b/webtools/hedweb/events.py
@@ -7,8 +7,7 @@
 from hed.errors.error_reporter import get_printable_issue_string
 from hed.errors.exceptions import HedFileError
 from hed.validator.event_validator import EventValidator
-from hedweb.constants import common, file_constants
-from hedweb.dictionary import dictionary_validate
+from hedweb.constants import common
 from hedweb.web_utils import form_has_option, get_hed_schema_from_pull_down, generate_filename
 
 app_config = current_app.config
@@ -34,21 +33,14 @@ def get_input_from_events_form(request):
 
     json_dictionary = None
     if common.JSON_FILE in request.files:
+        # json_string = f.read(file_constants.BYTE_LIMIT).decode('ascii')
+        # f = io.StringIO(request.files[common.JSON_FILE].read(file_constants.BYTE_LIMIT).decode('ascii'))
         f = request.files[common.JSON_FILE]
-        json_dictionary = models.ColumnDefGroup(json_string=f.read(file_constants.BYTE_LIMIT).decode('ascii'),
-                                                display_name=secure_filename(f.filename))
+        json_dictionary = models.ColumnDefGroup(file=f,name=secure_filename(f.filename))
     if common.EVENTS_FILE in request.files:
         f = request.files[common.EVENTS_FILE]
-        if json_dictionary:
-            def_dicts = json_dictionary.extract_defs()
-        else:
-            def_dicts = None
-        arguments[common.EVENTS] = models.EventsInput(filename=f, file_type=".tsv",
-                                                      json_def_files=json_dictionary, def_dicts=def_dicts,
-                                                      display_name=secure_filename(f.filename))
-        # arguments[common.EVENTS] = models.EventsInput(csv_string=f.read(file_constants.BYTE_LIMIT).decode('ascii'),
-        #                                               json_def_files=json_dictionary,
-        #                                               display_name=secure_filename(f.filename))
+        arguments[common.EVENTS] = \
+            models.EventsInput(filename=f, json_def_files=json_dictionary, name=secure_filename(f.filename))
     return arguments
 
 
@@ -113,7 +105,7 @@ def events_assemble(hed_schema, events, defs_expand=True):
     data = {'onset': onsets, 'HED': hed_tags}
     df = pd.DataFrame(data)
     csv_string = df.to_csv(None, sep='\t', index=False, header=True)
-    display_name = events.display_name
+    display_name = events.name
     file_name = generate_filename(display_name, suffix='_expanded', extension='.tsv')
     return {common.COMMAND: common.COMMAND_ASSEMBLE, 'data': csv_string, 'output_display_name': file_name,
             'schema_version': schema_version, 'msg_category': 'success',
@@ -136,18 +128,9 @@ def events_validate(hed_schema, events):
          A dictionary containing results of validation in standard format
     """
 
-    for json_dictionary in events.column_group_defs:
-        if json_dictionary:
-            results = dictionary_validate(hed_schema, json_dictionary)
-            if results['data']:
-                return results
-
     schema_version = hed_schema.header_attributes.get('version', 'Unknown version')
-    display_name = events.display_name
-    def_dicts = events.def_dicts
-    issues = []
-    if def_dicts:
-        issues = def_dicts[0].get_def_issues(hed_schema)
+    display_name = events.name
+    issues = events.validate_file_sidecars(hed_schema)
     if not issues:
         validator = EventValidator(hed_schema=hed_schema)
         issues = validator.validate_input(events)
diff --git a/webtools/hedweb/schema.py b/webtools/hedweb/schema.py
index ce8df81a2..ef653afd7 100644
--- a/webtools/hedweb/schema.py
+++ b/webtools/hedweb/schema.py
@@ -4,7 +4,6 @@
 from werkzeug.utils import secure_filename
 
 from hed import schema as hedschema
-from hed.schema import schema_compliance
 from hed.util.file_util import get_file_extension
 from hed.errors.error_reporter import get_printable_issue_string
 from hed.errors.exceptions import HedFileError
@@ -139,7 +138,7 @@ def schema_validate(hed_schema, display_name):
     """
 
     schema_version = hed_schema.header_attributes.get('version', 'Unknown')
-    issues = schema_compliance.check_compliance(hed_schema)
+    issues = hed_schema.check_compliance()
     if issues:
         issue_str = get_printable_issue_string(issues, f"Schema HED 3G compliance errors for {display_name}")
         file_name = generate_filename(display_name, suffix='schema_3G_compliance_errors', extension='.txt')
diff --git a/webtools/hedweb/services.py b/webtools/hedweb/services.py
index 38ec51607..fd48ac37f 100644
--- a/webtools/hedweb/services.py
+++ b/webtools/hedweb/services.py
@@ -45,8 +45,8 @@ def get_input_from_service_request(request):
                  common.CHECK_FOR_WARNINGS: parameters.get(common.CHECK_FOR_WARNINGS, True),
                  common.DEFS_EXPAND: parameters.get(common.DEFS_EXPAND, True)}
     if common.JSON_STRING in parameters and parameters[common.JSON_STRING]:
-        arguments[common.JSON_DICTIONARY] = models.ColumnDefGroup(json_string=parameters[common.JSON_STRING],
-                                                                  display_name='JSON_Dictionary')
+        arguments[common.JSON_DICTIONARY] = models.ColumnDefGroup(file=io.StringIO(parameters[common.JSON_STRING]),
+                                                                  name='JSON_Dictionary')
     if common.EVENTS_STRING in parameters and parameters[common.EVENTS_STRING]:
         if arguments[common.JSON_DICTIONARY]:
             def_dicts = arguments[common.JSON_DICTIONARY].extract_defs()
@@ -54,13 +54,13 @@ def get_input_from_service_request(request):
             def_dicts = None
         arguments[common.EVENTS] = models.EventsInput(filename=io.StringIO(parameters[common.EVENTS_STRING]),
                                                       json_def_files=arguments[common.JSON_DICTIONARY],
-                                                      def_dicts=def_dicts, file_type='.tsv', display_name='Events')
+                                                      def_dicts=def_dicts, file_type='.tsv', name='Events')
     if common.SPREADSHEET_STRING in parameters and parameters[common.SPREADSHEET_STRING]:
         tag_columns, prefix_dict = get_prefix_dict(parameters)
         arguments[common.SPREADSHEET] = \
             models.HedInput(filename=io.StringIO(parameters[common.SPREADSHEET_STRING]), file_type=".tsv",
                             tag_columns=tag_columns, has_column_names=arguments.get(common.HAS_COLUMN_NAMES, None),
-                            column_prefix_dictionary=prefix_dict, display_name='spreadsheet.tsv')
+                            column_prefix_dictionary=prefix_dict, name='spreadsheet.tsv')
     if common.SCHEMA_STRING in parameters and parameters[common.SCHEMA_STRING]:
         arguments[common.SCHEMA] = hedschema.from_string(parameters[common.SCHEMA_STRING])
     elif common.SCHEMA_URL in parameters and parameters[common.SCHEMA_URL]:
diff --git a/webtools/hedweb/spreadsheet.py b/webtools/hedweb/spreadsheet.py
index c69517528..592df0a47 100644
--- a/webtools/hedweb/spreadsheet.py
+++ b/webtools/hedweb/spreadsheet.py
@@ -80,7 +80,7 @@ def get_input_from_spreadsheet_form(request):
                                   tag_columns=tag_columns,
                                   has_column_names=arguments.get(common.HAS_COLUMN_NAMES, None),
                                   column_prefix_dictionary=prefix_dict,
-                                  display_name=filename)
+                                  name=filename)
     arguments[common.SPREADSHEET] = spreadsheet
     return arguments
 
@@ -140,7 +140,7 @@ def spreadsheet_convert(hed_schema, spreadsheet, command=common.COMMAND_TO_LONG)
     if results['data']:
         return results
 
-    display_name = spreadsheet.display_name
+    display_name = spreadsheet.name
     display_ext = os.path.splitext(secure_filename(display_name))[1]
 
     if command == common.COMMAND_TO_LONG:
@@ -174,7 +174,7 @@ def spreadsheet_validate(hed_schema, spreadsheet):
     schema_version = hed_schema.header_attributes.get('version', 'Unknown version')
     validator = EventValidator(hed_schema=hed_schema)
     issues = validator.validate_input(spreadsheet)
-    display_name = spreadsheet.display_name
+    display_name = spreadsheet.name
     if issues:
         issue_str = get_printable_issue_string(issues, f"Spreadsheet {display_name} validation errors")
         file_name = generate_filename(display_name, suffix='_validation_errors', extension='.txt')


Test patch:
diff --git a/webtools/tests/data/HED8.0.0-beta.4.xml b/webtools/tests/data/HED8.0.0-beta.4.xml
index 465525762..7319c8e23 100644
--- a/webtools/tests/data/HED8.0.0-beta.4.xml
+++ b/webtools/tests/data/HED8.0.0-beta.4.xml
@@ -1,5 +1,5 @@
 <?xml version="1.0" ?>
-<HED version="8.0.0-beta.4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://github.com/hed-standard/hed-specification/raw/master/hedxml/HED8.0.0-beta.3.xsd">
+<HED xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="8.0.0-beta.4" xsi:noNamespaceSchemaLocation="https://github.com/hed-standard/hed-specification/raw/master/hedxml/HED8.0.0-beta.3.xsd">
    <prologue>This schema is the first version that includes an xsd and requires unit class, unit modifier, value class, schema attribute and property sections.
 </prologue>
    <schema>
@@ -392,141 +392,69 @@
                <name>Move-body-part</name>
                <description>Move one part of a body.</description>
                <node>
-                  <name>Move-head</name>
-                  <description>Move head.</description>
-                  <node>
-                     <name>Move-eyes</name>
-                     <description>Move eyes.</description>
-                     <node>
-                        <name>Blink</name>
-                        <description>Shut and open the eyes quickly.</description>
-                     </node>
-                     <node>
-                        <name>Close-eyes</name>
-                        <description>Lower and keep eyelids in a closed position.</description>
-                     </node>
-                     <node>
-                        <name>Fixate</name>
-                        <description>Direct eyes to a specific point or target.</description>
-                     </node>
-                     <node>
-                        <name>Inhibit-blinks</name>
-                        <description>Purposely prevent blinking.</description>
-                     </node>
-                     <node>
-                        <name>Open-eyes</name>
-                        <description>Raise eyelids to expose pupil.</description>
-                     </node>
-                     <node>
-                        <name>Saccade</name>
-                        <description>Move eyes rapidly between fixation points.</description>
-                     </node>
-                     <node>
-                        <name>Stare</name>
-                        <description>Look fixedly or vacantly at someone or something with eyes wide open.</description>
-                     </node>
-                  </node>
-                  <node>
-                     <name>Move-face</name>
-                     <description>Move the face or jaw.</description>
-                     <node>
-                        <name>Bite</name>
-                        <description>Seize with teeth or jaws an object or organism so as to grip or break the surface covering.</description>
-                     </node>
-                     <node>
-                        <name>Burp</name>
-                        <description>Noisily release air from the stomach through the mouth; belch.</description>
-                     </node>
-                     <node>
-                        <name>Chew</name>
-                        <description>Repeatedly grinding, tearing, and or crushing with teeth or jaws.</description>
-                     </node>
-                     <node>
-                        <name>Gurgle</name>
-                        <description>Make a hollow bubbling sound like that made by water running out of a bottle.</description>
-                     </node>
-                     <node>
-                        <name>Swallow</name>
-                        <description>Cause or allow something, especially food or drink to pass down the throat.</description>
-                     </node>
-                     <node>
-                        <name>Yawn</name>
-                        <description>Take a deep involuntary  inhalation with the mouth open often as a sign of drowsiness or boredom.</description>
-                     </node>
-                  </node>
-               </node>
-               <node>
-                  <name>Move-upper-extremity</name>
-                  <description>Move arm, shoulder, and/or hand.</description>
+                  <name>Move-eyes</name>
+                  <description>Move eyes.</description>
                   <node>
-                     <name>Drop</name>
-                     <description>Let or cause to fall vertically.</description>
+                     <name>Blink</name>
+                     <description>Shut and open the eyes quickly.</description>
                   </node>
                   <node>
-                     <name>Grab</name>
-                     <description>Seize suddenly or quickly. Snatch or clutch.</description>
+                     <name>Close-eyes</name>
+                     <description>Lower and keep eyelids in a closed position.</description>
                   </node>
                   <node>
-                     <name>Grasp</name>
-                     <description>Seize and hold firmly.</description>
+                     <name>Fixate</name>
+                     <description>Direct eyes to a specific point or target.</description>
                   </node>
                   <node>
-                     <name>Hold-down</name>
-                     <description>Prevent someone or something from moving by holding them firmly.</description>
+                     <name>Inhibit-blinks</name>
+                     <description>Purposely prevent blinking.</description>
                   </node>
                   <node>
-                     <name>Lift</name>
-                     <description>Raising something to higher position.</description>
+                     <name>Open-eyes</name>
+                     <description>Raise eyelids to expose pupil.</description>
                   </node>
                   <node>
-                     <name>Make-fist</name>
-                     <description>Close hand tightly with the fingers bent against the palm.</description>
+                     <name>Saccade</name>
+                     <description>Move eyes rapidly between fixation points.</description>
                   </node>
                   <node>
-                     <name>Point</name>
-                     <description>Draw attention to something by extending a finger or arm.</description>
-                  </node>
-                  <node>
-                     <name>Press</name>
-                     <description>Apply pressure to something to flatten, shape, smooth or depress it. This action tag should be used to indicate key presses and mouse clicks.</description>
-                     <attribute>
-                        <name>relatedTag</name>
-                        <value>Push</value>
-                     </attribute>
-                  </node>
-                  <node>
-                     <name>Push</name>
-                     <description>Apply force in order to move something away. Use Press to indicate a key press or mouse click.</description>
-                     <attribute>
-                        <name>relatedTag</name>
-                        <value>Press</value>
-                     </attribute>
+                     <name>Stare</name>
+                     <description>Look fixedly or vacantly at someone or something with eyes wide open.</description>
                   </node>
+               </node>
+               <node>
+                  <name>Move-face</name>
+                  <description>Move the face or jaw.</description>
                   <node>
-                     <name>Reach</name>
-                     <description>Stretch out your arm in order to get or touch something.</description>
+                     <name>Bite</name>
+                     <description>Seize with teeth or jaws an object or organism so as to grip or break the surface covering.</description>
                   </node>
                   <node>
-                     <name>Release</name>
-                     <description>Make available; set free.</description>
+                     <name>Burp</name>
+                     <description>Noisily release air from the stomach through the mouth; belch.</description>
                   </node>
                   <node>
-                     <name>Retract</name>
-                     <description>Draw or pull back.</description>
+                     <name>Chew</name>
+                     <description>Repeatedly grinding, tearing, and or crushing with teeth or jaws.</description>
                   </node>
                   <node>
-                     <name>Scratch</name>
-                     <description>Drag claws or nails over a surface or on skin.</description>
+                     <name>Gurgle</name>
+                     <description>Make a hollow bubbling sound like that made by water running out of a bottle.</description>
                   </node>
                   <node>
-                     <name>Snap-fingers</name>
-                     <description>Make a noise by pushing second finger hard against thumb and then releasing it suddenly so that it hits the base of the thumb.</description>
+                     <name>Swallow</name>
+                     <description>Cause or allow something, especially food or drink to pass down the throat.</description>
                   </node>
                   <node>
-                     <name>Touch</name>
-                     <description>Come into or be in contact with.</description>
+                     <name>Yawn</name>
+                     <description>Take a deep involuntary  inhalation with the mouth open often as a sign of drowsiness or boredom.</description>
                   </node>
                </node>
+               <node>
+                  <name>Move-head</name>
+                  <description>Move head.</description>
+               </node>
                <node>
                   <name>Move-lower-extremity</name>
                   <description>Move leg and/or foot.</description>
@@ -583,6 +511,78 @@
                      <description>Move at a regular pace by lifting and setting down each foot in turn never having both feet off the ground at once.</description>
                   </node>
                </node>
+               <node>
+                  <name>Move-upper-extremity</name>
+                  <description>Move arm, shoulder, and/or hand.</description>
+                  <node>
+                     <name>Drop</name>
+                     <description>Let or cause to fall vertically.</description>
+                  </node>
+                  <node>
+                     <name>Grab</name>
+                     <description>Seize suddenly or quickly. Snatch or clutch.</description>
+                  </node>
+                  <node>
+                     <name>Grasp</name>
+                     <description>Seize and hold firmly.</description>
+                  </node>
+                  <node>
+                     <name>Hold-down</name>
+                     <description>Prevent someone or something from moving by holding them firmly.</description>
+                  </node>
+                  <node>
+                     <name>Lift</name>
+                     <description>Raising something to higher position.</description>
+                  </node>
+                  <node>
+                     <name>Make-fist</name>
+                     <description>Close hand tightly with the fingers bent against the palm.</description>
+                  </node>
+                  <node>
+                     <name>Point</name>
+                     <description>Draw attention to something by extending a finger or arm.</description>
+                  </node>
+                  <node>
+                     <name>Press</name>
+                     <description>Apply pressure to something to flatten, shape, smooth or depress it. This action tag should be used to indicate key presses and mouse clicks.</description>
+                     <attribute>
+                        <name>relatedTag</name>
+                        <value>Push</value>
+                     </attribute>
+                  </node>
+                  <node>
+                     <name>Push</name>
+                     <description>Apply force in order to move something away. Use Press to indicate a key press or mouse click.</description>
+                     <attribute>
+                        <name>relatedTag</name>
+                        <value>Press</value>
+                     </attribute>
+                  </node>
+                  <node>
+                     <name>Reach</name>
+                     <description>Stretch out your arm in order to get or touch something.</description>
+                  </node>
+                  <node>
+                     <name>Release</name>
+                     <description>Make available; set free.</description>
+                  </node>
+                  <node>
+                     <name>Retract</name>
+                     <description>Draw or pull back.</description>
+                  </node>
+                  <node>
+                     <name>Scratch</name>
+                     <description>Drag claws or nails over a surface or on skin.</description>
+                  </node>
+                  <node>
+                     <name>Snap-fingers</name>
+                     <description>Make a noise by pushing second finger hard against thumb and then releasing it suddenly so that it hits the base of the thumb.</description>
+                  </node>
+                  <node>
+                     <name>Touch</name>
+                     <description>Come into or be in contact with.</description>
+                  </node>
+               </node>
             </node>
          </node>
          <node>
@@ -2256,7 +2256,7 @@
                      </attribute>
                      <attribute>
                         <name>unitClass</name>
-                        <value>acceleration</value>
+                        <value>accelerationUnits</value>
                      </attribute>
                      <attribute>
                         <name>valueClass</name>
@@ -2274,7 +2274,7 @@
                      </attribute>
                      <attribute>
                         <name>unitClass</name>
-                        <value>jerk</value>
+                        <value>jerkUnits</value>
                      </attribute>
                      <attribute>
                         <name>valueClass</name>
@@ -2292,7 +2292,7 @@
                      </attribute>
                      <attribute>
                         <name>unitClass</name>
-                        <value>frequency</value>
+                        <value>frequencyUnits</value>
                      </attribute>
                   </node>
                </node>
@@ -2320,7 +2320,7 @@
                      </attribute>
                      <attribute>
                         <name>unitClass</name>
-                        <value>speed</value>
+                        <value>speedUnits</value>
                      </attribute>
                      <attribute>
                         <name>valueClass</name>
@@ -2338,7 +2338,7 @@
                      </attribute>
                      <attribute>
                         <name>unitClass</name>
-                        <value>frequency</value>
+                        <value>frequencyUnits</value>
                      </attribute>
                   </node>
                </node>
@@ -2428,7 +2428,7 @@
                      </attribute>
                      <attribute>
                         <name>unitClass</name>
-                        <value>physicalLength</value>
+                        <value>physicalLengthUnits</value>
                      </attribute>
                      <attribute>
                         <name>valueClass</name>
@@ -2463,7 +2463,7 @@
                         </attribute>
                         <attribute>
                            <name>unitClass</name>
-                           <value>physicalLength</value>
+                           <value>physicalLengthUnits</value>
                         </attribute>
                         <attribute>
                            <name>valueClass</name>
@@ -2481,7 +2481,7 @@
                         </attribute>
                         <attribute>
                            <name>unitClass</name>
-                           <value>physicalLength</value>
+                           <value>physicalLengthUnits</value>
                         </attribute>
                         <attribute>
                            <name>valueClass</name>
@@ -2499,7 +2499,7 @@
                         </attribute>
                         <attribute>
                            <name>unitClass</name>
-                           <value>physicalLength</value>
+                           <value>physicalLengthUnits</value>
                         </attribute>
                         <attribute>
                            <name>valueClass</name>
@@ -2521,7 +2521,7 @@
                         </attribute>
                         <attribute>
                            <name>unitClass</name>
-                           <value>area</value>
+                           <value>areaUnits</value>
                         </attribute>
                         <attribute>
                            <name>valueClass</name>
@@ -2539,7 +2539,7 @@
                         </attribute>
                         <attribute>
                            <name>unitClass</name>
-                           <value>physicalLength</value>
+                           <value>physicalLengthUnits</value>
                         </attribute>
                         <attribute>
                            <name>valueClass</name>
@@ -2557,7 +2557,7 @@
                         </attribute>
                         <attribute>
                            <name>unitClass</name>
-                           <value>physicalLength</value>
+                           <value>physicalLengthUnits</value>
                         </attribute>
                         <attribute>
                            <name>valueClass</name>
@@ -2575,7 +2575,7 @@
                         </attribute>
                         <attribute>
                            <name>unitClass</name>
-                           <value>physicalLength</value>
+                           <value>physicalLengthUnits</value>
                         </attribute>
                         <attribute>
                            <name>valueClass</name>
@@ -2593,7 +2593,7 @@
                         </attribute>
                         <attribute>
                            <name>unitClass</name>
-                           <value>volume</value>
+                           <value>volumeUnits</value>
                         </attribute>
                         <attribute>
                            <name>valueClass</name>
@@ -2603,7 +2603,7 @@
                   </node>
                </node>
                <node>
-                  <name>Surface-properties</name>
+                  <name>Surface-property</name>
                   <description>Property of the outer boundary of a three-dimensional object.</description>
                   <node>
                      <name>Rough</name>
@@ -2628,7 +2628,7 @@
                      </attribute>
                      <attribute>
                         <name>unitClass</name>
-                        <value>time</value>
+                        <value>timeUnits</value>
                      </attribute>
                      <attribute>
                         <name>valueClass</name>
@@ -2646,7 +2646,7 @@
                      </attribute>
                      <attribute>
                         <name>unitClass</name>
-                        <value>time</value>
+                        <value>timeUnits</value>
                      </attribute>
                      <attribute>
                         <name>valueClass</name>
@@ -2664,7 +2664,7 @@
                      </attribute>
                      <attribute>
                         <name>unitClass</name>
-                        <value>frequency</value>
+                        <value>frequencyUnits</value>
                      </attribute>
                      <attribute>
                         <name>valueClass</name>
@@ -2700,7 +2700,7 @@
                      </attribute>
                      <attribute>
                         <name>unitClass</name>
-                        <value>time</value>
+                        <value>timeUnits</value>
                      </attribute>
                      <attribute>
                         <name>valueClass</name>
@@ -2717,6 +2717,69 @@
                   <description>A synchronization signal whose purpose to help synchronize different signals or processes. Often used to indicate a marker inserted into the recorded data to allow post hoc synchronization of concurrently recorded data streams.</description>
                </node>
             </node>
+            <node>
+               <name>Variability-property</name>
+               <description>An attribute describing how something changes or varies.</description>
+               <node>
+                  <name>Abrupt</name>
+                  <description>Marked by sudden change.</description>
+               </node>
+               <node>
+                  <name>Constant</name>
+                  <description>Continually recurring or continuing without interruption. Not changing in time or space.</description>
+               </node>
+               <node>
+                  <name>Continuous</name>
+                  <description>Uninterrupted in time, sequence, substance, or extent.</description>
+               </node>
+               <node>
+                  <name>Deterministic</name>
+                  <description>No randomness is involved in the development of the future states of the element.</description>
+                  <attribute>
+                     <name>relatedTag</name>
+                     <value>Random</value>
+                     <value>Stochastic</value>
+                  </attribute>
+               </node>
+               <node>
+                  <name>Discrete</name>
+                  <description>Constituting a separate entities or parts.</description>
+               </node>
+               <node>
+                  <name>Flickering</name>
+                  <description>Moving irregularly or unsteadily or burning or shining fitfully or with a fluctuating light.</description>
+               </node>
+               <node>
+                  <name>Fractal</name>
+                  <description>Having extremely irregular curves or shapes for which any suitably chosen part is similar in shape to a given larger or smaller part when magnified or reduced to the same size.</description>
+               </node>
+               <node>
+                  <name>Random</name>
+                  <description>Governed by or depending on chance; lacking any definite plan or order or purpose.</description>
+                  <attribute>
+                     <name>relatedTag</name>
+                     <value>Deterministic</value>
+                     <value>Stochastic</value>
+                  </attribute>
+               </node>
+               <node>
+                  <name>Repetitive</name>
+                  <description>A recurring action that is often non-purposeful.</description>
+               </node>
+               <node>
+                  <name>Stochastic</name>
+                  <description>Uses  a random probability distribution or pattern that may be analysed statistically but may not be predicted precisely to determine future states.</description>
+                  <attribute>
+                     <name>relatedTag</name>
+                     <value>Deterministic</value>
+                     <value>Random</value>
+                  </attribute>
+               </node>
+               <node>
+                  <name>Varying</name>
+                  <description>Differing in size, amount, degree, or nature.</description>
+               </node>
+            </node>
          </node>
          <node>
             <name>Statistical-property</name>
@@ -3941,6 +4004,9 @@
                <attribute>
                   <name>topLevelTagGroup</name>
                </attribute>
+               <attribute>
+                  <name>unique</name>
+               </attribute>
             </node>
             <node>
                <name>Event-stream</name>
@@ -4209,7 +4275,7 @@
                      <description>(A (Between, (B, C))) means A is in the space or interval separating B and C.</description>
                   </node>
                   <node>
-                     <name>Bilateral</name>
+                     <name>Bilateral-to</name>
                      <description>(A (Bilateral B)) means A is on both sides of B or affects both sides of B.</description>
                   </node>
                   <node>
@@ -4301,69 +4367,6 @@
                      <description>(A Waiting-for B) means A pauses for something to happen in B.</description>
                   </node>
                </node>
-               <node>
-                  <name>Variability-relation</name>
-                  <description>An attribute describing how something changes or varies.</description>
-                  <node>
-                     <name>Abrupt</name>
-                     <description>Marked by sudden change.</description>
-                  </node>
-                  <node>
-                     <name>Constant</name>
-                     <description>Continually recurring or continuing without interruption. Not changing in time or space.</description>
-                  </node>
-                  <node>
-                     <name>Continuous</name>
-                     <description>Uninterrupted in time, sequence, substance, or extent.</description>
-                  </node>
-                  <node>
-                     <name>Deterministic</name>
-                     <description>No randomness is involved in the development of the future states of the element.</description>
-                     <attribute>
-                        <name>relatedTag</name>
-                        <value>Random</value>
-                        <value>Stochastic</value>
-                     </attribute>
-                  </node>
-                  <node>
-                     <name>Discrete</name>
-                     <description>Constituting a separate entities or parts.</description>
-                  </node>
-                  <node>
-                     <name>Flickering</name>
-                     <description>Moving irregularly or unsteadily or burning or shining fitfully or with a fluctuating light.</description>
-                  </node>
-                  <node>
-                     <name>Fractal</name>
-                     <description>Having extremely irregular curves or shapes for which any suitably chosen part is similar in shape to a given larger or smaller part when magnified or reduced to the same size.</description>
-                  </node>
-                  <node>
-                     <name>Random</name>
-                     <description>Governed by or depending on chance; lacking any definite plan or order or purpose.</description>
-                     <attribute>
-                        <name>relatedTag</name>
-                        <value>Deterministic</value>
-                        <value>Stochastic</value>
-                     </attribute>
-                  </node>
-                  <node>
-                     <name>Repetitive</name>
-                     <description>A recurring action that is often non-purposeful.</description>
-                  </node>
-                  <node>
-                     <name>Stochastic</name>
-                     <description>Uses  a random probability distribution or pattern that may be analysed statistically but may not be predicted precisely to determine future states.</description>
-                     <attribute>
-                        <name>relatedTag</name>
-                        <value>Deterministic</value>
-                        <value>Random</value>
-                     </attribute>
-                  </node>
-                  <node>
-                     <name>Varying</name>
-                     <description>Differing in size, amount, degree, or nature.</description>
-                  </node>
-               </node>
             </node>
             <node>
                <name>Thermal-relation</name>
@@ -5320,7 +5323,7 @@
    </schema>
    <unitClassDefinitions>
       <unitClassDefinition>
-         <name>acceleration</name>
+         <name>accelerationUnits</name>
          <attribute>
             <name>defaultUnits</name>
             <value>m-per-s^2</value>
@@ -5336,7 +5339,7 @@
          </unit>
       </unitClassDefinition>
       <unitClassDefinition>
-         <name>angle</name>
+         <name>angleUnits</name>
          <attribute>
             <name>defaultUnits</name>
             <value>radian</value>
@@ -5361,7 +5364,7 @@
          </unit>
       </unitClassDefinition>
       <unitClassDefinition>
-         <name>area</name>
+         <name>areaUnits</name>
          <attribute>
             <name>defaultUnits</name>
             <value>m^2</value>
@@ -5375,18 +5378,9 @@
                <name>unitSymbol</name>
             </attribute>
          </unit>
-         <unit>
-            <name>px^2</name>
-            <attribute>
-               <name>unitSymbol</name>
-            </attribute>
-         </unit>
-         <unit>
-            <name>pixel^2</name>
-         </unit>
       </unitClassDefinition>
       <unitClassDefinition>
-         <name>currency</name>
+         <name>currencyUnits</name>
          <description>Units indicating the worth of something.</description>
          <attribute>
             <name>defaultUnits</name>
@@ -5409,7 +5403,7 @@
          </unit>
       </unitClassDefinition>
       <unitClassDefinition>
-         <name>frequency</name>
+         <name>frequencyUnits</name>
          <attribute>
             <name>defaultUnits</name>
             <value>Hz</value>
@@ -5431,45 +5425,28 @@
          </unit>
       </unitClassDefinition>
       <unitClassDefinition>
-         <name>intensity</name>
+         <name>intensityUnits</name>
          <attribute>
             <name>defaultUnits</name>
             <value>dB</value>
          </attribute>
          <unit>
             <name>dB</name>
+            <description>Intensity expressed as ratio to a threshold. Often used for sound intensity.</description>
             <attribute>
                <name>unitSymbol</name>
             </attribute>
          </unit>
-      </unitClassDefinition>
-      <unitClassDefinition>
-         <name>jerk</name>
-         <attribute>
-            <name>defaultUnits</name>
-            <value>m-per-s^3</value>
-         </attribute>
-         <unit>
-            <name>m-per-s^3</name>
-            <attribute>
-               <name>unitSymbol</name>
-            </attribute>
-         </unit>
-      </unitClassDefinition>
-      <unitClassDefinition>
-         <name>luminousIntensity</name>
-         <attribute>
-            <name>defaultUnits</name>
-            <value>cd</value>
-         </attribute>
          <unit>
             <name>candela</name>
+            <description>Units used to express light intensity.</description>
             <attribute>
                <name>SIUnit</name>
             </attribute>
          </unit>
          <unit>
             <name>cd</name>
+            <description>Units used to express light intensity.</description>
             <attribute>
                <name>SIUnit</name>
             </attribute>
@@ -5479,7 +5456,20 @@
          </unit>
       </unitClassDefinition>
       <unitClassDefinition>
-         <name>memorySize</name>
+         <name>jerkUnits</name>
+         <attribute>
+            <name>defaultUnits</name>
+            <value>m-per-s^3</value>
+         </attribute>
+         <unit>
+            <name>m-per-s^3</name>
+            <attribute>
+               <name>unitSymbol</name>
+            </attribute>
+         </unit>
+      </unitClassDefinition>
+      <unitClassDefinition>
+         <name>memorySizeUnits</name>
          <attribute>
             <name>defaultUnits</name>
             <value>B</value>
@@ -5501,11 +5491,17 @@
          </unit>
       </unitClassDefinition>
       <unitClassDefinition>
-         <name>physicalLength</name>
+         <name>physicalLengthUnits</name>
          <attribute>
             <name>defaultUnits</name>
             <value>m</value>
          </attribute>
+         <unit>
+            <name>foot</name>
+         </unit>
+         <unit>
+            <name>inch</name>
+         </unit>
          <unit>
             <name>metre</name>
             <attribute>
@@ -5521,31 +5517,12 @@
                <name>unitSymbol</name>
             </attribute>
          </unit>
-         <unit>
-            <name>foot</name>
-         </unit>
          <unit>
             <name>mile</name>
          </unit>
       </unitClassDefinition>
       <unitClassDefinition>
-         <name>pixels</name>
-         <attribute>
-            <name>defaultUnits</name>
-            <value>px</value>
-         </attribute>
-         <unit>
-            <name>pixel</name>
-         </unit>
-         <unit>
-            <name>px</name>
-            <attribute>
-               <name>unitSymbol</name>
-            </attribute>
-         </unit>
-      </unitClassDefinition>
-      <unitClassDefinition>
-         <name>speed</name>
+         <name>speedUnits</name>
          <attribute>
             <name>defaultUnits</name>
             <value>m-per-s</value>
@@ -5573,7 +5550,7 @@
          </unit>
       </unitClassDefinition>
       <unitClassDefinition>
-         <name>time</name>
+         <name>timeUnits</name>
          <attribute>
             <name>defaultUnits</name>
             <value>s</value>
@@ -5605,7 +5582,7 @@
          </unit>
       </unitClassDefinition>
       <unitClassDefinition>
-         <name>volume</name>
+         <name>volumeUnits</name>
          <attribute>
             <name>defaultUnits</name>
             <value>m^3</value>
diff --git a/webtools/tests/data/bids_events.json b/webtools/tests/data/bids_events.json
index 2fd094b84..5c5307c1f 100644
--- a/webtools/tests/data/bids_events.json
+++ b/webtools/tests/data/bids_events.json
@@ -20,14 +20,14 @@
             "right-raised-nomatch": "Subject raised right hand and computer presented image of left hand."
         },
         "HED": {
-          "cue": "Description/Subject presses both buttons causing cue bar to start count-down display, (Sensory-event, Visual-modality, Cue, ((Rectangle, (Position, (Center-of, Computer-screen)), (Size, Decreasing)))), (Agent-action, Experiment-participant, (Press, Hold-down, (Left-side, Mouse-button)), (Press, Hold-down, (Right-side, Mouse-button)))",
-          "go": "Description/Onset of the go signal which is the disappearance of the cue bar, Sensory-event, (Visual-modality, Experimental-stimulus, Instructional, Rectangle)",
+          "cue": "Description/Subject presses both buttons causing cue bar to start count-down display, (Sensory-event, Visual, Cue, ((Rectangle, (Position, (Center-of, Computer-screen)), (Size, Decreasing)))), (Agent-action, Experiment-participant, (Press, Hold-down, (Left-side, Mouse-button)), (Press, Hold-down, (Right-side, Mouse-button)))",
+          "go": "Description/Onset of the go signal which is the disappearance of the cue bar, Sensory-event, (Visual, Experimental-stimulus, Instructional, Rectangle)",
           "right-raised": "Description/Subject raised right hand thereby releasing right button, (Agent-action, Experiment-participant, (Lift, (Right-side, Hand)), (Release, (Right-side, Mouse-button)))",
           "left-raised": "Description/Subject raised left hand thereby releasing left button, (Agent-action, Experiment-participant, (Lift, (Left-side, Hand)), (Release, (Left-side, Mouse-button)))",
-          "left-raised-match": "Description/Computer presented image of left hand thereby matching a previously raised left hand, (Sensory-event, Visual-modality, (Drawing, ID/left_hand.png,(Left-side, Hand)), (Feedback, (Intended-effect, Penalty)))",
-          "left-raised-nomatch": "Description/Computer presented image of left hand thereby not matching previously raised right hand, (Sensory-event, Visual-modality, (Drawing, ID/right_hand.png, (Left-side, Hand)), (Feedback, (Intended-effect, Reward)))",
-          "right-raised-match": "Description/Computer presented image of right hand thereby matching a previously raised right hand, (Sensory-event, Visual-modality, (Drawing, ID/right_hand.png,(Right-side, Hand)), (Feedback, (Intended-effect, Penalty)))",
-          "right-raised-nomatch": "Description/Computer presented image of right hand thereby not matching a previously raised left hand, (Sensory-event, Visual-modality, (Drawing, ID/right_hand.png, (Right-side, Hand)), (Feedback, (Intended-effect, Reward)))"
+          "left-raised-match": "Description/Computer presented image of left hand thereby matching a previously raised left hand, (Sensory-event, Visual, (Drawing, ID/left_hand.png,(Left-side, Hand)), (Feedback, (Intended-effect, Penalty)))",
+          "left-raised-nomatch": "Description/Computer presented image of left hand thereby not matching previously raised right hand, (Sensory-event, Visual, (Drawing, ID/right_hand.png, (Left-side, Hand)), (Feedback, (Intended-effect, Reward)))",
+          "right-raised-match": "Description/Computer presented image of right hand thereby matching a previously raised right hand, (Sensory-event, Visual, (Drawing, ID/right_hand.png,(Right-side, Hand)), (Feedback, (Intended-effect, Penalty)))",
+          "right-raised-nomatch": "Description/Computer presented image of right hand thereby not matching a previously raised left hand, (Sensory-event, Visual, (Drawing, ID/right_hand.png, (Right-side, Hand)), (Feedback, (Intended-effect, Reward)))"
         }
 	},
     "sample": {
diff --git a/webtools/tests/test_dictionary.py b/webtools/tests/test_dictionary.py
index 074967ea2..e15032acb 100644
--- a/webtools/tests/test_dictionary.py
+++ b/webtools/tests/test_dictionary.py
@@ -73,7 +73,7 @@ def test_dictionary_process(self):
         json_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/bids_events.json')
         schema_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/HED7.2.0.xml')
         hed_schema = hedschema.load_schema(hed_file_path=schema_path)
-        json_dictionary = models.ColumnDefGroup(json_filename=json_path, display_name='bids_json')
+        json_dictionary = models.ColumnDefGroup(file=json_path, name='bids_json')
         arguments = {common.SCHEMA: hed_schema, common.JSON_DICTIONARY: json_dictionary,
                      common.JSON_DISPLAY_NAME: 'bids_json', common.COMMAND: common.COMMAND_TO_SHORT}
         with self.app.app_context():
@@ -102,7 +102,7 @@ def test_dictionary_convert_to_long(self):
         from hedweb.dictionary import dictionary_convert
         from hedweb.constants import common
         json_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/bids_events.json')
-        json_dictionary = models.ColumnDefGroup(json_filename=json_path, display_name='bids_events')
+        json_dictionary = models.ColumnDefGroup(file=json_path, name='bids_events')
         schema_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/HED7.2.0.xml')
         hed_schema = hedschema.load_schema(hed_file_path=schema_path)
         arguments = {common.SCHEMA: hed_schema,
@@ -127,7 +127,7 @@ def test_dictionary_convert_to_short(self):
         from hed import models
         from hedweb.dictionary import dictionary_convert
         json_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/bids_events.json')
-        json_dictionary = models.ColumnDefGroup(json_filename=json_path, display_name='bids_events')
+        json_dictionary = models.ColumnDefGroup(file=json_path, name='bids_events')
         schema_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/HED7.2.0.xml')
         hed_schema = hedschema.load_schema(hed_file_path=schema_path)
         with self.app.app_context():
@@ -149,7 +149,7 @@ def test_dictionary_validate(self):
         from hed import models
         from hedweb.dictionary import dictionary_validate
         json_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/bids_events.json')
-        json_dictionary = models.ColumnDefGroup(json_filename=json_path, display_name='bids_events')
+        json_dictionary = models.ColumnDefGroup(file=json_path, name='bids_events')
         schema_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/HED7.2.0.xml')
         hed_schema = hedschema.load_schema(hed_file_path=schema_path)
         with self.app.app_context():
diff --git a/webtools/tests/test_events.py b/webtools/tests/test_events.py
index 8271c8a73..e9932378a 100644
--- a/webtools/tests/test_events.py
+++ b/webtools/tests/test_events.py
@@ -77,10 +77,8 @@ def test_events_process(self):
         json_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/bids_events.json')
         schema_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/HED8.0.0-beta.4.xml')
         hed_schema = hedschema.load_schema(hed_file_path=schema_path)
-        json_dictionary = models.ColumnDefGroup(json_filename=json_path, display_name='bids_json')
-        def_dicts = json_dictionary.extract_defs()
-        events = models.EventsInput(filename=events_path, json_def_files=json_dictionary,
-                                    display_name='bids_events', def_dicts=def_dicts)
+        json_dictionary = models.ColumnDefGroup(file=json_path, name='bids_json')
+        events = models.EventsInput(filename=events_path, json_def_files=json_dictionary, name='bids_events')
         arguments = {common.EVENTS: events, common.COMMAND: common.COMMAND_VALIDATE, common.DEFS_EXPAND: True,
                      common.CHECK_FOR_WARNINGS: True, common.SCHEMA: hed_schema}
         with self.app.app_context():
@@ -106,10 +104,8 @@ def test_events_assemble(self):
         json_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/bids_events.json')
         schema_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/HED8.0.0-beta.4.xml')
         hed_schema = hedschema.load_schema(hed_file_path=schema_path)
-        json_dictionary = models.ColumnDefGroup(json_filename=json_path, display_name='bids_json')
-        def_dicts = json_dictionary.extract_defs()
-        events = models.EventsInput(filename=events_path, json_def_files=json_dictionary,
-                                    display_name='bids_events', def_dicts=def_dicts)
+        json_dictionary = models.ColumnDefGroup(file=json_path, name='bids_json')
+        events = models.EventsInput(filename=events_path, json_def_files=json_dictionary,name='bids_events')
         with self.app.app_context():
             results = events_assemble(hed_schema, events, defs_expand=True)
             self.assertTrue('data' in results,
@@ -132,11 +128,8 @@ def test_events_validate(self):
         json_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/bids_events.json')
         schema_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'data/HED7.2.0.xml')
         hed_schema = hedschema.load_schema(hed_file_path=schema_path)
-        json_dictionary = models.ColumnDefGroup(json_filename=json_path, display_name='bids_json')
-        def_dicts = json_dictionary.extract_defs()
-        events = models.EventsInput(filename=events_path, json_def_files=json_dictionary,
-                                    def_dicts=def_dicts, display_name='bids_events')
-
+        json_dictionary = models.ColumnDefGroup(file=json_path, name='bids_json')
+        events = models.EventsInput(filename=events_path, json_def_files=json_dictionary, name='bids_events')
         with self.app.app_context():
             results = events_validate(hed_schema, events)
             self.assertTrue(results['data'],
diff --git a/webtools/tests/test_services.py b/webtools/tests/test_services.py
index 4418d2880..f532328d8 100644
--- a/webtools/tests/test_services.py
+++ b/webtools/tests/test_services.py
@@ -1,4 +1,5 @@
 import os
+import io
 import json
 import shutil
 import unittest
@@ -78,10 +79,11 @@ def test_process_services_dictionary(self):
         with open(json_path) as f:
             data = json.load(f)
         json_text = json.dumps(data)
+        fb = io.StringIO(json_text)
         schema_url = 'https://raw.githubusercontent.com/hed-standard/hed-specification/master/' \
                      + 'hedxml-test/HED8.0.0-beta.4.xml'
         hed_schema = hedschema.load_schema(hed_url_path=schema_url)
-        json_dictionary = models.ColumnDefGroup(json_string=json_text, display_name='JSON_Dictionary')
+        json_dictionary = models.ColumnDefGroup(file=fb, name='JSON_Dictionary')
         arguments = {common.SERVICE: 'dictionary_validate', common.SCHEMA: hed_schema,
                      common.JSON_DICTIONARY: json_dictionary}
         with self.app.app_context():
diff --git a/webtools/tests/test_spreadsheet.py b/webtools/tests/test_spreadsheet.py
index 38b7a0612..e3b800d24 100644
--- a/webtools/tests/test_spreadsheet.py
+++ b/webtools/tests/test_spreadsheet.py
@@ -89,7 +89,7 @@ def test_spreadsheet_process_validate_invalid(self):
                                       tag_columns=[5],
                                       has_column_names=True,
                                       column_prefix_dictionary=prefix_dict,
-                                      display_name=spreadsheet_path)
+                                      name=spreadsheet_path)
         arguments = {common.SCHEMA: hed_schema, common.SPREADSHEET: spreadsheet,
                      common.COMMAND: common.COMMAND_VALIDATE, common.CHECK_FOR_WARNINGS: True}
         with self.app.app_context():
@@ -112,7 +112,7 @@ def test_spreadsheet_process_validate_valid(self):
                                       tag_columns=[5],
                                       has_column_names=True,
                                       column_prefix_dictionary=prefix_dict,
-                                      display_name=spreadsheet_path)
+                                      name=spreadsheet_path)
         arguments = {common.SCHEMA: hed_schema, common.SPREADSHEET: spreadsheet,
                      common.COMMAND: common.COMMAND_VALIDATE, common.CHECK_FOR_WARNINGS: True}
         arguments[common.SCHEMA] = hed_schema
@@ -135,7 +135,7 @@ def test_spreadsheet_validate_valid_excel(self):
                                       tag_columns=[5],
                                       has_column_names=True,
                                       column_prefix_dictionary=prefix_dict,
-                                      display_name=spreadsheet_path)
+                                      name=spreadsheet_path)
         with self.app.app_context():
             results = spreadsheet_validate(hed_schema, spreadsheet)
             self.assertFalse(results['data'],
@@ -154,7 +154,7 @@ def test_spreadsheet_validate_valid_excel1(self):
                                       tag_columns=[5],
                                       has_column_names=True,
                                       column_prefix_dictionary=prefix_dict,
-                                      display_name=spreadsheet_path)
+                                      name=spreadsheet_path)
         with self.app.app_context():
             results = spreadsheet_validate(hed_schema, spreadsheet)
             self.assertFalse(results['data'],
@@ -173,7 +173,7 @@ def test_spreadsheet_validate_invalid_excel(self):
                                       tag_columns=[5],
                                       has_column_names=True,
                                       column_prefix_dictionary=prefix_dict,
-                                      display_name=spreadsheet_path)
+                                      name=spreadsheet_path)
         with self.app.app_context():
             results = spreadsheet_validate(hed_schema, spreadsheet)
             self.assertTrue(results['data'],
diff --git a/webtools/tests/test_web_utils.py b/webtools/tests/test_web_utils.py
index ffa371b20..5af112098 100644
--- a/webtools/tests/test_web_utils.py
+++ b/webtools/tests/test_web_utils.py
@@ -106,7 +106,7 @@ def test_generate_download_spreadsheet_excel(self):
                                    tag_columns=[5], has_column_names=True,
                                    column_prefix_dictionary={2: 'Attribute/Informational/Label/',
                                                              4: 'Attribute/Informational/Description/'},
-                                   display_name='ExcelOneSheet.xlsx')
+                                   name='ExcelOneSheet.xlsx')
             results = {common.SPREADSHEET: spreadsheet, common.OUTPUT_DISPLAY_NAME: 'ExcelOneSheetA.xlsx'}
             response = generate_download_spreadsheet(results, msg_category='success', msg='Successful download')
             self.assertIsInstance(response, Response, 'generate_download_spreadsheet returns a response for xlsx files')
@@ -128,7 +128,7 @@ def test_generate_download_spreadsheet_excel_code(self):
                                    tag_columns=[5], has_column_names=True,
                                    column_prefix_dictionary={2: 'Attribute/Informational/Label/',
                                                              4: 'Attribute/Informational/Description/'},
-                                   display_name='ExcelOneSheet.xlsx')
+                                   name='ExcelOneSheet.xlsx')
             results = {common.SPREADSHEET: spreadsheet, common.OUTPUT_DISPLAY_NAME: 'ExcelOneSheetA.xlsx'}
             response = generate_download_spreadsheet(results, msg_category='success', msg='Successful download')
             self.assertIsInstance(response, Response, 'generate_download_spreadsheet returns a response for tsv files')
@@ -151,7 +151,7 @@ def test_generate_download_spreadsheet_tsv(self):
                                    tag_columns=[5], has_column_names=True,
                                    column_prefix_dictionary={2: 'Attribute/Informational/Label/',
                                                              4: 'Attribute/Informational/Description/'},
-                                   display_name='LKTEventCodesHED3.tsv')
+                                   name='LKTEventCodesHED3.tsv')
             results = {common.SPREADSHEET: spreadsheet, common.OUTPUT_DISPLAY_NAME: 'LKTEventCodesHED3.tsv'}
             response = generate_download_spreadsheet(results, msg_category='success', msg='Successful download')
             self.assertIsInstance(response, Response, 'generate_download_spreadsheet returns a response for tsv files')