oapi-profile-builder 3.7.0__tar.gz → 3.7.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (20) hide show
  1. {oapi_profile_builder-3.7.0/src/oapi_profile_builder.egg-info → oapi_profile_builder-3.7.2}/PKG-INFO +1 -1
  2. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/pyproject.toml +1 -1
  3. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder/generate.py +38 -10
  4. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2/src/oapi_profile_builder.egg-info}/PKG-INFO +1 -1
  5. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/LICENSE +0 -0
  6. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/README.md +0 -0
  7. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/setup.cfg +0 -0
  8. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder/__init__.py +0 -0
  9. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder/cite.py +0 -0
  10. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder/cite_features.py +0 -0
  11. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder/cli.py +0 -0
  12. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder/compile.py +0 -0
  13. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder/cover.py +0 -0
  14. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder/models.py +0 -0
  15. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder/server_validation.py +0 -0
  16. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder.egg-info/SOURCES.txt +0 -0
  17. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder.egg-info/dependency_links.txt +0 -0
  18. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder.egg-info/entry_points.txt +0 -0
  19. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder.egg-info/requires.txt +0 -0
  20. {oapi_profile_builder-3.7.0 → oapi_profile_builder-3.7.2}/src/oapi_profile_builder.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: oapi-profile-builder
3
- Version: 3.7.0
3
+ Version: 3.7.2
4
4
  Summary: Authoritative tooling for creating OGC API Service Profiles (EDR, Features)
5
5
  Author-email: Shane Mill <shane.mill@noaa.gov>
6
6
  License: Apache License
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "oapi-profile-builder"
7
- version = "3.7.0"
7
+ version = "3.7.2"
8
8
  description = "Authoritative tooling for creating OGC API Service Profiles (EDR, Features)"
9
9
  readme = "README.md"
10
10
  license = { file = "LICENSE" }
@@ -427,8 +427,9 @@ _POST_BODY_SCHEMAS: dict[str, dict] = {
427
427
  "crs": {"type": "string", "description": "Identifier for the coordinate reference system"},
428
428
  "f": {"type": "string", "description": "Response format"},
429
429
  },
430
- }
431
430
  },
431
+ }
432
+
432
433
  def _post_operation(get_op: dict, query_type: str, coll: object, responses: dict) -> dict:
433
434
  """Build a POST operation mirroring a GET EDR data query operation."""
434
435
  body_schema = _POST_BODY_SCHEMAS.get(query_type, {"type": "object"})
@@ -675,21 +676,48 @@ def _collection_response_schema(coll: Collection,
675
676
  if coll.extent and coll.extent.temporal:
676
677
  t = coll.extent.temporal
677
678
  temporal_props = {"trs": {"type": "string", **_const(t.trs, version)}}
678
- if t.interval: temporal_props["interval"] = {"type": "array", **_const(t.interval, version)}
679
- if t.values: temporal_props["values"] = {"type": "array", **_const(t.values, version)}
679
+ if t.interval:
680
+ temporal_props["interval"] = {
681
+ "type": "array",
682
+ "items": {"type": "array", "items": {"type": "string", "nullable": True}},
683
+ **_const(t.interval, version)
684
+ }
685
+ if t.values:
686
+ temporal_props["values"] = {
687
+ "type": "array",
688
+ "items": {"type": "string"},
689
+ **_const(t.values, version)
690
+ }
680
691
  extent_props["temporal"] = {"type": "object", "required": ["trs"], "properties": temporal_props}
681
692
  if coll.extent and coll.extent.vertical:
682
693
  v = coll.extent.vertical
683
694
  vertical_props = {"vrs": {"type": "string", **_const(v.vrs, version)}}
684
- if v.interval: vertical_props["interval"] = {"type": "array", **_const(v.interval, version)}
685
- if v.values: vertical_props["values"] = {"type": "array", **_const(v.values, version)}
695
+ if v.interval:
696
+ vertical_props["interval"] = {
697
+ "type": "array",
698
+ "items": {"type": "array", "items": {"type": "number"}},
699
+ **_const(v.interval, version)
700
+ }
701
+ if v.values:
702
+ vertical_props["values"] = {
703
+ "type": "array",
704
+ "items": {"type": "string"},
705
+ **_const(v.values, version)
706
+ }
686
707
  if getattr(v, "positive", None): vertical_props["positive"] = {"type": "string", **_const(v.positive, version)}
687
708
  extent_props["vertical"] = {"type": "object", "required": ["vrs"], "properties": vertical_props}
688
709
  if coll.extent and coll.extent.custom:
689
- custom_items = [{"type": "object", "required": ["id", "interval", "reference"],
690
- "properties": {"id": {"type": "string", **_const(c.id, version)},
691
- "interval": {"type": "array", **_const(c.interval, version)},
692
- "reference": {"type": "string", **_const(c.reference, version)}}} for c in coll.extent.custom]
710
+ custom_items = []
711
+ for c in coll.extent.custom:
712
+ custom_items.append({
713
+ "type": "object",
714
+ "required": ["id", "interval", "reference"],
715
+ "properties": {
716
+ "id": {"type": "string", **_const(c.id, version)},
717
+ "interval": {"type": "array", "items": {"type": "string"}, **_const(c.interval, version)},
718
+ "reference": {"type": "string", **_const(c.reference, version)},
719
+ }
720
+ })
693
721
  extent_props["custom"] = {"type": "array", "items": {"oneOf": custom_items}}
694
722
 
695
723
  dq_props = {}
@@ -719,7 +747,7 @@ def _collection_response_schema(coll: Collection,
719
747
  "id": {"type": "string", **_const(coll.id, version)},
720
748
  "title": {"type": "string", **_const(coll.title, version)} if coll.title else {"type": "string"},
721
749
  "description": {"type": "string", **_const(coll.description, version)} if coll.description else {"type": "string"},
722
- "keywords": {"type": "array", "items": {"type": "string", "enum": coll.keywords}} if coll.keywords else {"type": "array"},
750
+ "keywords": {"type": "array", "items": {"type": "string"}},
723
751
  "links": _LINKS_ARRAY, "crs": crs_array_schema, "output_formats": output_formats_schema,
724
752
  "parameter_names": param_names_schema,
725
753
  "extent": {"type": "object", "required": ["spatial"], "properties": extent_props},
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: oapi-profile-builder
3
- Version: 3.7.0
3
+ Version: 3.7.2
4
4
  Summary: Authoritative tooling for creating OGC API Service Profiles (EDR, Features)
5
5
  Author-email: Shane Mill <shane.mill@noaa.gov>
6
6
  License: Apache License