mapbox-gl-js icon indicating copy to clipboard operation
mapbox-gl-js copied to clipboard

Style spec validator allows `projection.name = 'globe'` for GL JS `2.6.0`

Open AlexanderBelokon opened this issue 3 years ago • 0 comments

The styles-spec's sdk-support field only specifies versions for fields, not for values: https://github.com/mapbox/mapbox-gl-js/blob/b13b0aed81d9d552da9cec0f570bdb52b8750137/src/style-spec/reference/v8.json#L4112

This can lead to users unintentionally marking their styles as supported by GL JS 2.6.0, even though globe projection (which is now the default) was not yet supported at that time.

studio-globe-supported-260

mapbox-gl-js version: 2.9.1

browser: Firefox 101.0.1

Steps to Trigger Behavior

  1. Login to Studio
  2. Create a new style (with globe projection by default)
  3. (optional) Disable atmosphere to prevent warnings about it
  4. Switch Settings -> Supported Mapbox SDK versions -> Mapbox GL JS to 2.6.0
  5. Notice that there are no warnings about projection (or anything at all, if you removed atmosphere) from GL JS

Expected Behavior

A warning about globe projection is displayed

Actual Behavior

No warning is displayed

AlexanderBelokon avatar Jun 21 '22 23:06 AlexanderBelokon