diff --git a/CHANGELOG.md b/CHANGELOG.md index 2c857a8..02e9c4f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Change log +### 0.3.6 - 2026-04-10 +- Fixed https://dev.azure.com/TDEI-UW/TDEI/_workitems/edit/3469 +- Added regression coverage for `tests/assets/task_3469.zip` to assert the exact per-feature `issues` payload: `"null" is not one of "down" or "up"` on `FIFA_sidewalks.edges.geojson` feature index `0`. +- Aligned package dependency pins by updating `setup.py` to `jsonschema_rs==0.33.0` (matching `requirements.txt`). + ### 0.3.5 - 2026-03-16 - Fixed filename-based schema selection to use exact dataset suffixes such as `.nodes.geojson`, `.edges.geojson`, and the legacy `.nodes.OSW.geojson` form instead of loose substring matching. - Prevented false schema selection for filenames with misleading prefixes such as `gs_metaline_falls_uga.nodes.geojson` and `gs_yarrow_point.edges.geojson`. diff --git a/requirements.txt b/requirements.txt index 190d0ea..0df4504 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,4 +1,4 @@ -jsonschema_rs -zipfile36 +jsonschema_rs==0.33.0 +zipfile36==0.1.3 coverage geopandas==0.14.4 \ No newline at end of file diff --git a/setup.py b/setup.py index 2b26333..782358e 100644 --- a/setup.py +++ b/setup.py @@ -19,7 +19,7 @@ long_description_content_type='text/markdown', url='https://github.com/TaskarCenterAtUW/TDEI-python-lib-osw-validation', install_requires=[ - 'jsonschema_rs==0.26.1', + 'jsonschema_rs==0.33.0', 'zipfile36==0.1.3', 'geopandas==0.14.4' ], diff --git a/src/python_osw_validation/version.py b/src/python_osw_validation/version.py index 40ed83d..4596d03 100644 --- a/src/python_osw_validation/version.py +++ b/src/python_osw_validation/version.py @@ -1 +1 @@ -__version__ = '0.3.5' +__version__ = '0.3.6' diff --git a/tests/assets/task_3469.zip b/tests/assets/task_3469.zip new file mode 100644 index 0000000..8c91771 Binary files /dev/null and b/tests/assets/task_3469.zip differ diff --git a/tests/unit_tests/test_osw_validation.py b/tests/unit_tests/test_osw_validation.py index 167f92f..2cb1b43 100644 --- a/tests/unit_tests/test_osw_validation.py +++ b/tests/unit_tests/test_osw_validation.py @@ -38,6 +38,7 @@ def setUp(self): self.invalid_zones_file = os.path.join(ASSETS_PATH, 'UW.zones.invalid.zip') self.valid_osw_file = os.path.join(ASSETS_PATH, 'wa.bellevue.zip') self.invalid_v_id_file = os.path.join(ASSETS_PATH, '4151.zip') + self.task_3469_file = os.path.join(ASSETS_PATH, 'task_3469.zip') self.serialization_file = os.path.join(ASSETS_PATH, 'test_serialization_error.zip') self.schema_file_path = SCHEMA_FILE_PATH self.schema_paths = SCHEMA_PATHS @@ -267,6 +268,31 @@ def test_unmatched_ids_limited_to_20(self): # Ensure the total count is mentioned self.assertIn('Showing 20 out of', error_message) + def test_task_3469_issue_payload(self): + validation = OSWValidation(zipfile_path=self.task_3469_file) + result = validation.validate() + self.assertFalse(result.is_valid) + self.assertEqual( + result.issues, + [{ + 'filename': 'FIFA_sidewalks.edges.geojson', + 'feature_index': 0, + 'error_message': ['"null" is not one of "down" or "up"'], + }] + ) + + def test_jsonschema_rs_pin_is_0_33_0(self): + requirements_path = os.path.join(SRC_DIR, 'requirements.txt') + setup_path = os.path.join(SRC_DIR, 'setup.py') + + with open(requirements_path, 'r', encoding='utf-8') as f: + requirements_content = f.read() + with open(setup_path, 'r', encoding='utf-8') as f: + setup_content = f.read() + + self.assertIn('jsonschema_rs==0.33.0', requirements_content) + self.assertIn('jsonschema_rs==0.33.0', setup_content) + if __name__ == '__main__': unittest.main()