Skip to content

Wmts Probe #406

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 45 commits into from
Feb 8, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
65206e3
add wmts probe
JukeofHolland Oct 1, 2021
3fa8134
added deepcopy to avoid changing the resource parameters itself
JukeofHolland Oct 1, 2021
8169caf
bug fix. Added comma
JukeofHolland Oct 1, 2021
019db0c
added tilerow to gettileall
JukeofHolland Oct 4, 2021
7979605
Rest changed to REST
JukeofHolland Oct 15, 2021
add0d5a
generic request template kvprest
JukeofHolland Oct 15, 2021
4bb3681
new request template tested and confirmed
JukeofHolland Oct 15, 2021
839c359
image formats
JukeofHolland Oct 15, 2021
a6e4db5
flake8 check
JukeofHolland Oct 18, 2021
34021f1
all of the changes based on review
JukeofHolland Oct 22, 2021
68964e7
error
jochemthart1 Oct 28, 2021
2173d3a
review 25-10
jochemthart1 Oct 28, 2021
2a47611
Merge branch 'geopython:master' into wmts-rest-issue
jochemthart1 Oct 28, 2021
2f0de48
removed some print statements
jochemthart1 Oct 28, 2021
cada144
fix for REST without WMTSCapabilities.xml
jochemthart1 Oct 29, 2021
1f4e98c
comments
jochemthart1 Oct 29, 2021
d35b9e7
flake8
jochemthart1 Oct 29, 2021
51de086
hardcoded fix for REST GetCap
jochemthart1 Oct 29, 2021
649e987
flake8
jochemthart1 Oct 29, 2021
24c0868
fixed url issue
jochemthart1 Oct 29, 2021
e8e02d0
make sure original url stays the same
jochemthart1 Oct 29, 2021
e9f1ad8
remove redundant folder
jochemthart1 Oct 29, 2021
3d136aa
Merge pull request #1 from jochemthart1/wmts-rest-issue
jochemthart1 Oct 29, 2021
85bcebe
degree calculation formula changed
jochemthart1 Nov 4, 2021
8723ff0
comments added
jochemthart1 Nov 4, 2021
b69f8b9
Merge branch 'geopython:master' into wmts-probe
jochemthart1 Nov 25, 2021
5130867
perform_request adjusted
JukeofHolland Dec 6, 2021
52ba7af
kvp format
JukeofHolland Dec 9, 2021
5acaf3d
flake8
JukeofHolland Dec 9, 2021
86a0eeb
remove print
JukeofHolland Dec 10, 2021
9eb0728
Merge branch 'geopython:master' into wmts-probe
jochemthart1 Dec 23, 2021
cf43c48
wmts tests added
JukeofHolland Dec 23, 2021
1bf4fe0
change to gettile instead of gettileall
JukeofHolland Dec 23, 2021
a53340f
bugfix
JukeofHolland Dec 23, 2021
cef3bdc
added checks
JukeofHolland Dec 23, 2021
ef4136f
add wmts gettileall kvp test resource
JukeofHolland Dec 24, 2021
dd1ad4b
other pdok resource
JukeofHolland Dec 24, 2021
9a1eaf4
random sample zoom levels
JukeofHolland Jan 6, 2022
4ac5509
Merge branch 'geopython:master' into wmts-probe
jochemthart1 Jan 6, 2022
4c68608
Sample tilematrixsets instead of zoomlevels
JukeofHolland Jan 7, 2022
554adc9
test random image format
JukeofHolland Jan 7, 2022
cbfc216
user input sample/all and coordinates
JukeofHolland Jan 25, 2022
16350c5
tests adjusted for sample
JukeofHolland Jan 25, 2022
0bd6cf7
flake8 check
JukeofHolland Jan 25, 2022
ff2003b
Merge branch 'geopython:master' into wmts-probe
jochemthart1 Jan 25, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions GeoHealthCheck/config_main.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@
# Probes
'GeoHealthCheck.plugins.probe.owsgetcaps',
'GeoHealthCheck.plugins.probe.wms',
'GeoHealthCheck.plugins.probe.wmts',
'GeoHealthCheck.plugins.probe.wfs',
'GeoHealthCheck.plugins.probe.tms',
'GeoHealthCheck.plugins.probe.http',
Expand Down
23 changes: 23 additions & 0 deletions GeoHealthCheck/plugins/probe/owsgetcaps.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,29 @@ def __init__(self):
})
"""Param defs"""

# This is to catch errors because url is only accessible through REST
# owslib will always do KVP request and this way the GetCap url will be:
# .../1.0.0/WMTSCapabilities.xml?service=WMTS&version=1.0.0&
# request=GetCapabilities
# This new request will return a valid WebMapTileService object.
def before_request(self):
self.original_url = self._resource.url

try:
response = Probe.perform_get_request(self, self._resource.url)
except Exception:
self._resource.url = self._resource.url + \
'/1.0.0/WMTSCapabilities.xml'
return

if (response.status_code != 200 and
'<ServiceException' in response.text):
self._resource.url = self._resource.url + \
'/1.0.0/WMTSCapabilities.xml'

def after_request(self):
self._resource.url = self.original_url


class WpsGetCaps(OwsGetCaps):
"""WPS GetCapabilities Probe"""
Expand Down
Loading