Skip to content

Commit 3e7aff3

Browse files
committed
update
1 parent 8e813e0 commit 3e7aff3

File tree

2 files changed

+25
-38
lines changed

2 files changed

+25
-38
lines changed

pycsw/ogc/csw/csw2.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -716,7 +716,6 @@ def getrecords(self):
716716
LOGGER.debug('OpenSearch Geo/Time parameters to Filter: %s.', self.parent.kvp['constraint'])
717717

718718
if self.parent.requesttype == 'GET':
719-
print("GET")
720719
if 'constraint' in self.parent.kvp:
721720
# GET request
722721
LOGGER.debug('csw:Constraint passed over HTTP GET.')
@@ -782,7 +781,6 @@ def getrecords(self):
782781
return self.exceptionreport('InvalidParameterValue',
783782
'constraint', 'Invalid Filter query: %s' % errortext)
784783
else:
785-
print("NOT GET")
786784
if self.parent.repository.database is not None:
787785
self.parent.kvp['constraint'] = {}
788786
else:
@@ -826,7 +824,6 @@ def getrecords(self):
826824
if 'startposition' not in self.parent.kvp or not self.parent.kvp['startposition']:
827825
self.parent.kvp['startposition'] = 1
828826

829-
print(self.parent.kvp['constraint'])
830827
# query repository
831828
LOGGER.debug('Querying repository with constraint: %s,\
832829
sortby: %s, typenames: %s, maxrecords: %s, startposition: %s',
@@ -1608,8 +1605,6 @@ def _parse_constraint(self, element):
16081605
#query['ast'] = PycswCSWFES11Parser().parse(etree.tostring(tmp))
16091606
query['ast'] = fes1_parse(etree.tostring(tmp))
16101607
except Exception as err:
1611-
import traceback
1612-
print(traceback.format_exc())
16131608
return 'Invalid Filter request: %s' % err
16141609

16151610
tmp = element.find(util.nspath_eval('csw:CqlText', self.parent.context.namespaces))
@@ -1638,7 +1633,6 @@ def parse_postdata(self, postdata):
16381633
request = {}
16391634
try:
16401635
LOGGER.info('Parsing %s', postdata)
1641-
print("JJJ", postdata)
16421636
doc = etree.fromstring(postdata, self.parent.context.parser)
16431637
except Exception as err:
16441638
errortext = \

tests/functionaltests/suites/default/expected/post_GetRecords-all-sortby-bbox.xml

Lines changed: 25 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -3,38 +3,6 @@
33
<csw:GetRecordsResponse xmlns:csw="http://www.opengis.net/cat/csw/2.0.2" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:dct="http://purl.org/dc/terms/" xmlns:gmd="http://www.isotc211.org/2005/gmd" xmlns:gml="http://www.opengis.net/gml" xmlns:gml32="http://www.opengis.net/gml/3.2" xmlns:ows="http://www.opengis.net/ows" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="2.0.2" xsi:schemaLocation="http://www.opengis.net/cat/csw/2.0.2 http://schemas.opengis.net/csw/2.0.2/CSW-discovery.xsd">
44
<csw:SearchStatus timestamp="PYCSW_TIMESTAMP"/>
55
<csw:SearchResults numberOfRecordsMatched="12" numberOfRecordsReturned="5" nextRecord="6" recordSchema="http://www.opengis.net/cat/csw/2.0.2" elementSet="full">
6-
<csw:Record>
7-
<dc:identifier>urn:uuid:1ef30a8b-876d-4828-9246-c37ab4510bbd</dc:identifier>
8-
<dc:type>http://purl.org/dc/dcmitype/Service</dc:type>
9-
<dct:abstract>Proin sit amet justo. In justo. Aenean adipiscing nulla id tellus.</dct:abstract>
10-
<ows:BoundingBox crs="urn:x-ogc:def:crs:EPSG:6.11:4326">
11-
<ows:LowerCorner>60.042 13.754</ows:LowerCorner>
12-
<ows:UpperCorner>68.410 17.920</ows:UpperCorner>
13-
</ows:BoundingBox>
14-
</csw:Record>
15-
<csw:Record>
16-
<dc:identifier>urn:uuid:9a669547-b69b-469f-a11f-2d875366bbdc</dc:identifier>
17-
<dc:type>http://purl.org/dc/dcmitype/Dataset</dc:type>
18-
<dc:title>Ñunç elementum</dc:title>
19-
<dc:subject scheme="http://www.digest.org/2.1">Hydrography-Oceanographic</dc:subject>
20-
<dc:date>2005-10-24</dc:date>
21-
<ows:BoundingBox crs="urn:x-ogc:def:crs:EPSG:6.11:4326">
22-
<ows:LowerCorner>44.792 -6.171</ows:LowerCorner>
23-
<ows:UpperCorner>51.126 -2.228</ows:UpperCorner>
24-
</ows:BoundingBox>
25-
</csw:Record>
26-
<csw:Record>
27-
<dc:identifier>urn:uuid:94bc9c83-97f6-4b40-9eb8-a8e8787a5c63</dc:identifier>
28-
<dc:type>http://purl.org/dc/dcmitype/Dataset</dc:type>
29-
<dc:title>Mauris sed neque</dc:title>
30-
<dc:subject scheme="http://www.digest.org/2.1">Vegetation-Cropland</dc:subject>
31-
<dct:abstract>Curabitur lacinia, ante non porta tempus, mi lorem feugiat odio, eget suscipit eros pede ac velit.</dct:abstract>
32-
<dc:date>2006-03-26</dc:date>
33-
<ows:BoundingBox crs="urn:x-ogc:def:crs:EPSG:6.11:4326">
34-
<ows:LowerCorner>47.595 -4.097</ows:LowerCorner>
35-
<ows:UpperCorner>51.217 0.889</ows:UpperCorner>
36-
</ows:BoundingBox>
37-
</csw:Record>
386
<csw:Record>
397
<dc:identifier>urn:uuid:19887a8a-f6b0-4a63-ae56-7fba0e17801f</dc:identifier>
408
<dc:type>http://purl.org/dc/dcmitype/Image</dc:type>
@@ -43,6 +11,15 @@
4311
<dct:spatial>GR-22</dct:spatial>
4412
<dc:subject>Tourism--Greece</dc:subject>
4513
<dct:abstract>Quisque lacus diam, placerat mollis, pharetra in, commodo sed, augue. Duis iaculis arcu vel arcu.</dct:abstract>
14+
</csw:Record>
15+
<csw:Record>
16+
<dc:identifier>urn:uuid:1ef30a8b-876d-4828-9246-c37ab4510bbd</dc:identifier>
17+
<dc:type>http://purl.org/dc/dcmitype/Service</dc:type>
18+
<dct:abstract>Proin sit amet justo. In justo. Aenean adipiscing nulla id tellus.</dct:abstract>
19+
<ows:BoundingBox crs="urn:x-ogc:def:crs:EPSG:6.11:4326">
20+
<ows:LowerCorner>60.042 13.754</ows:LowerCorner>
21+
<ows:UpperCorner>68.410 17.920</ows:UpperCorner>
22+
</ows:BoundingBox>
4623
</csw:Record>
4724
<csw:Record>
4825
<dc:identifier>urn:uuid:66ae76b7-54ba-489b-a582-0f0633d96493</dc:identifier>
@@ -51,6 +28,22 @@
5128
<dc:format>application/xhtml+xml</dc:format>
5229
<dc:subject>Marine sediments</dc:subject>
5330
<dct:abstract>Pellentesque tempus magna non sapien fringilla blandit.</dct:abstract>
31+
</csw:Record>
32+
<csw:Record>
33+
<dc:identifier>urn:uuid:6a3de50b-fa66-4b58-a0e6-ca146fdd18d4</dc:identifier>
34+
<dc:type>http://purl.org/dc/dcmitype/Service</dc:type>
35+
<dc:title>Ut facilisis justo ut lacus</dc:title>
36+
<dc:subject scheme="http://www.digest.org/2.1">Vegetation</dc:subject>
37+
<dc:relation>urn:uuid:94bc9c83-97f6-4b40-9eb8-a8e8787a5c63</dc:relation>
38+
</csw:Record>
39+
<csw:Record>
40+
<dc:identifier>urn:uuid:784e2afd-a9fd-44a6-9a92-a3848371c8ec</dc:identifier>
41+
<dc:title>Aliquam fermentum purus quis arcu</dc:title>
42+
<dc:type>http://purl.org/dc/dcmitype/Text</dc:type>
43+
<dc:subject>Hydrography--Dictionaries</dc:subject>
44+
<dc:format>application/pdf</dc:format>
45+
<dc:date>2006-05-12</dc:date>
46+
<dct:abstract>Vestibulum quis ipsum sit amet metus imperdiet vehicula. Nulla scelerisque cursus mi.</dct:abstract>
5447
</csw:Record>
5548
</csw:SearchResults>
5649
</csw:GetRecordsResponse>

0 commit comments

Comments
 (0)