Skip to content

Commit 61dad1f

Browse files
committed
update xml parsing to work with recent versions (5.4)
1 parent 902ab04 commit 61dad1f

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

CHANGES.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
Changes
33
=======
44

5+
0.4.3 (2023-05-31)
6+
==================
7+
8+
* fix xml parsing for recent versions
9+
510
0.4.2 (2019-11-20)
611
==================
712

tests/test_birdhouse_sample.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ def test_birdhouse_root():
3434
def test_birdhouse_top():
3535
xml = """
3636
<catalog xmlns="http://www.unidata.ucar.edu/namespaces/thredds/InvCatalog/v1.0" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.0.1"> # noqa
37-
<service name="all" serviceType="Compound" base="">
37+
<service name="all" serviceType="compound" base="">
3838
<service name="service4" serviceType="HTTPServer" base="/thredds/fileServer/" />
3939
<service name="odap" serviceType="OPENDAP" base="/thredds/dodsC/" />
4040
<service name="wcs" serviceType="WCS" base="/thredds/wcs/" />

threddsclient/catalog.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ def get_services(self, service_name):
158158
services = []
159159
for service in self.services:
160160
if service.name == service_name:
161-
if service.service_type == 'Compound':
161+
if service.service_type.lower() == 'Compound'.lower():
162162
services.extend(service.services)
163163
else:
164164
services.append(service)

0 commit comments

Comments
 (0)