When initializing the Map with a basemap, the basemap model_id is not added to the Map._layer_ids attribute, resulting in an error when trying to removing the basemap from the map. This PR fixes the bug by adding the basemap layer id to the Map._layer_ids attribute
import ipyleaflet
m = ipyleaflet.Map()
m
m.remove(m.layers[0])
When initializing the Map with a basemap, the basemap
model_id
is not added to theMap._layer_ids
attribute, resulting in an error when trying to removing the basemap from the map. This PR fixes the bug by adding the basemap layer id to theMap._layer_ids
attribute