Open prusswan opened 1 week ago
@prusswan
We made some updates with WMTSLayer at version 2.4.0. Can you update your version and see if this has been resolved?
@prusswan When using version 2.4.0 this is how the WMTS Timezone layer looks on the map:
Also for the other WMTS when attempting to add to the Map Viewer it makes you choose one layer:
@nanaeaubry thanks for the fast turnaround, mainly we are trying to fix/troubleshoot this for ArcGIS Pro and 2.4 will not be readily available (and will also require Python 3.10 and above). Also, as kernel errors are not well propagated to the user interface (when accessed from Pro), hopefully the API can display a simple error/informative message in case the "Add Layer" pop up fails.
It would be best to follow the JS api (https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-WMTSLayer.html) as much as possible since developers would be more familiar with that.
@prusswan
Sure we are now following the JS API a lot more at 2.4.0 since we introduced a new mapping package: arcgis-mapping
This uses the webmap spec to create maps and to deal with layers, popups, etc. We are more than welcome to take user feedback for this new package as well.
Unfortunately we do not backport fixes so the only way to benefit from this is to upgrade. I understand this can take some time to get there so I will leave the issue open and if you are able to try this at a later version and have requests we can continue with them here.
As far as a popup for the map, we can look into it but we are focused on automation and not re-creating the map viewer within a notebook. So we can look at other ways to accomplish this or having better documentation for users to understand what they are creating with the WMTSLayer class
Describe the bug
Could not get WMTSLayer to work with these services:
https://sampleserver6.arcgisonline.com/arcgis/rest/services/WorldTimeZones/MapServer/WMTS (from https://developers.arcgis.com/rest/services-reference/enterprise/wmts-map-service/)
https://gibs.earthdata.nasa.gov/wmts/epsg4326/best (from https://nasa-gibs.github.io/gibs-api-docs/access-basics/)
I inspected the Python code that is part of installed arcgis package, and realized that WMTSLayer is assuming that the WMTS service only has one layer and one tilematrixset. This is probably the main reason why those WMTS services are not working.
To Reproduce Steps to reproduce the behavior:
error:
Screenshots N/A
Expected behavior Python SDK should work with existing WMTS services, and display informative errors if there are truly issues with the WMTS services
Platform (please complete the following information):
Additional context Add any other context about the problem here, attachments etc.