Esri/esri-leaflet-vector

"Outdoor Map" vector tile layer - not working

gavinr opened this issue · 5 comments

Describe the bug

I am trying to load the new "Outdoor Map" vector tile layer using Esri Leaflet Vector: https://www.arcgis.com/home/item.html?id=659e7c1b1e374f6c8a89eefe17b23380 (mentioned here)

Reproduction

https://jsbin.com/yicugaqodu/1/edit?html,output

L.esri.Vector.vectorBasemapLayer("659e7c1b1e374f6c8a89eefe17b23380", {
    apikey: apiKey
}).addTo(map);
  • Expected: the basemap loads normally
  • Actual: the basemap does not load (gray page)

Logs

Error: layers[268].layout.stops: unknown property "stops"
    at Object.kr [as emitValidationErrors] (mapbox-gl.js:31:133534)
    at Ue (mapbox-gl.js:35:112388)
    at i._load (mapbox-gl.js:35:114931)
    at mapbox-gl.js:35:114551
    at mapbox-gl.js:31:17012

System Info

- leaflet@1.8.0
- esri-leaflet@^3.0.8
- esri-leaflet-vector@3.1.3

Additional Information

I'm not quite sure if this is something specific to this vector tile layer or if it's a general issue with Esri Leaflet trying to render "Multisource vector map styles" - I can update the issue title after we dig in and identify the issue.

Also experiencing the same issue. Commenting to bump this up in priority. Thanks.

I'm not quite sure if this is something specific to this vector tile layer or if it's a general issue with Esri Leaflet trying to render "Multisource vector map styles" - I can update the issue title after we dig in and identify the issue.

@gavinr

Attempting to rule out "Multisource vector map styles" issue, I've referenced the new World Topographic Map (with Contours and Hillshade) (another multisource map style) and the sample works as expected. If you look at it's style, it has stops both within the fill-color and the fill-opacity objects within the paint object of the VTL's styles/root.json just like the Outdoor VTL's style. The formatting of the 2 json files is different, but I don't see additional differences.

Seems to point to the issue being with the vector tile layer itself after this check.

The error is saying that in the style, in the layer array, index 268, the stops property should not exist in the layer:

image

I am trying to verify that with the vector tile layer style spec, but the documentation does not list the allowed properties:
image

That being said, since the mapbox-gl-js library is reporting it's invalid, I'm inclined to believe that. I will reach out to the owner of this style. Edit: the Esri Living Atlas team is investigating this.

The Esri Living Atlas team agrees that this is probably an issue with the Outdoor map style JSON. An update that will hopefully fix the issue should be released in ~2 weeks.

It seems like the style has been fixed and the error is not happening anymore.

https://jsbin.com/yicugaqodu/1/edit?html,output

image

There seems to be a different error (error Uncaught TypeError: Failed to construct 'Request': Failed to parse URL from tile/15/11273/16593.pbf ) that does not affect the map opening. I may create this as a separate issue.