Skip to content

Commit 0b38f3b

Browse files
committed
rename gsd to distancevalue
1 parent 4ab0dd9 commit 0b38f3b

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

pycsw/core/repository.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ def __init__(self, database, context, app_root=None, table='records', repo_filte
168168
'instrument': self.dataset.instrument,
169169
'sensortype': self.dataset.sensortype,
170170
'off_nadir': self.dataset.illuminationelevationangle,
171-
'gsd': self.dataset.distancevalue
171+
'distancevalue': self.dataset.distancevalue
172172
}
173173

174174
if self.dbtype == 'postgresql':
@@ -307,7 +307,8 @@ def describe(self):
307307

308308
type_mappings = {
309309
'TEXT': 'string',
310-
'VARCHAR': 'string'
310+
'VARCHAR': 'string',
311+
'FLOAT': 'number'
311312
}
312313

313314
properties = {

tests/functionaltests/suites/stac_api/test_stac_api_functional.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ def test_queryables(config):
134134
assert content['$id'] == 'http://localhost/pycsw/oarec/stac/collections/metadata:main/queryables' # noqa
135135
assert content['$schema'] == 'http://json-schema.org/draft/2019-09/schema'
136136

137-
assert len(content['properties']) == 17
137+
assert len(content['properties']) == 18
138138

139139
assert 'geometry' in content['properties']
140140
assert content['properties']['geometry']['$ref'] == 'https://geojson.org/schema/Polygon.json' # noqa
@@ -774,7 +774,7 @@ def test_items(config):
774774
'op': '<=',
775775
'args': [
776776
{
777-
'property': 'gsd'
777+
'property': 'distancevalue'
778778
},
779779
0.66
780780
]

0 commit comments

Comments
 (0)