Skip to content

Unknown feature value when calling queryRenderedFeatures #6742

@kamil-sienkiewicz-asi

Description

@kamil-sienkiewicz-asi

maplibre-gl-js version: 5.13.0

browser: chrome 141.0.7390.77

Steps to Trigger Behavior

  1. Add feature with properties: { value: undefined}
  2. Call queryRenderedFeatures
  3. Map throws "Error: unknown feature value"

Bonus: if instead of map.on('mousemove') I use map.on("move"), I'm also getting

  • Map throws Uncaught Error: Attempting to run(), but is already running.

Link to Demonstration

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

Expected Behavior

No error

Actual Behavior

Error :( and possibly freeze

Turf.js for example has type:

export declare type Properties = {
    [name: string]: any;
} | null;

which accepts anything in properties, not sure if I should use something else or maplibre should just discard such values 🤔

Metadata

Metadata

Assignees

No one assigned

    Labels

    need more infoFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions