|
8 | 8 | # Ricardo Garcia Silva <[email protected]> |
9 | 9 | # |
10 | 10 | # Copyright (c) 2025 Tom Kralidis |
11 | | -# Copyright (c) 2022 Francesco Bartoli |
| 11 | +# Copyright (c) 2025 Francesco Bartoli |
12 | 12 | # Copyright (c) 2022 John A Stevenson and Colin Blackburn |
13 | 13 | # Copyright (c) 2023 Ricardo Garcia Silva |
14 | 14 | # |
@@ -212,6 +212,7 @@ def example_method(api: API, request: APIRequest, custom_arg): |
212 | 212 | :param request: The web platform specific Request instance. |
213 | 213 | :param supported_locales: List or set of supported Locale instances. |
214 | 214 | """ |
| 215 | + |
215 | 216 | def __init__(self, request, supported_locales): |
216 | 217 | # Set default request data |
217 | 218 | self._data = b'' |
@@ -336,7 +337,7 @@ def _get_format(self, headers) -> Union[str, None]: |
336 | 337 |
|
337 | 338 | # Format not specified: get from Accept headers (MIME types) |
338 | 339 | # e.g. format_ = 'text/html' |
339 | | - h = headers.get('accept', headers.get('Accept', '')).strip() # noqa |
| 340 | + h = headers.get('accept', headers.get('Accept', '')).strip() # noqa |
340 | 341 | (fmts, mimes) = zip(*FORMAT_TYPES.items()) |
341 | 342 | # basic support for complex types (i.e. with "q=0.x") |
342 | 343 | for type_ in (t.split(';')[0].strip() for t in h.split(',') if t): |
@@ -1134,10 +1135,10 @@ def describe_collections(api: API, request: APIRequest, |
1134 | 1135 |
|
1135 | 1136 | # OAPIF Part 2 - list supported CRSs and StorageCRS |
1136 | 1137 | if collection_data_type in ['edr', 'feature']: |
1137 | | - collection['crs'] = get_supported_crs_list(collection_data, DEFAULT_CRS_LIST) # noqa |
1138 | | - collection['storageCRS'] = collection_data.get('storage_crs', DEFAULT_STORAGE_CRS) # noqa |
| 1138 | + collection['crs'] = get_supported_crs_list(collection_data, DEFAULT_CRS_LIST) # noqa |
| 1139 | + collection['storageCRS'] = collection_data.get('storage_crs', DEFAULT_STORAGE_CRS) # noqa |
1139 | 1140 | if 'storage_crs_coordinate_epoch' in collection_data: |
1140 | | - collection['storageCrsCoordinateEpoch'] = collection_data.get('storage_crs_coordinate_epoch') # noqa |
| 1141 | + collection['storageCrsCoordinateEpoch'] = collection_data.get('storage_crs_coordinate_epoch') # noqa |
1141 | 1142 |
|
1142 | 1143 | elif collection_data_type == 'coverage': |
1143 | 1144 | # TODO: translate |
@@ -1176,7 +1177,7 @@ def describe_collections(api: API, request: APIRequest, |
1176 | 1177 | collection['extent']['spatial']['grid'] = [{ |
1177 | 1178 | 'cellsCount': p._coverage_properties['width'], |
1178 | 1179 | 'resolution': p._coverage_properties['resx'] |
1179 | | - }, { |
| 1180 | + }, { |
1180 | 1181 | 'cellsCount': p._coverage_properties['height'], |
1181 | 1182 | 'resolution': p._coverage_properties['resy'] |
1182 | 1183 | }] |
|
0 commit comments