{"id":21518,"library":"leafmap","title":"Leafmap","description":"A Python package for geospatial analysis and interactive mapping in a Jupyter environment. Version 0.61.1, released monthly.","status":"active","version":"0.61.1","language":"python","source_language":"en","source_url":"https://github.com/opengeos/leafmap","tags":["geospatial","mapping","jupyter","interactive","gis"],"install":[{"cmd":"pip install leafmap","lang":"bash","label":"Default install"}],"dependencies":[{"reason":"Geospatial data handling","package":"geopandas","optional":false},{"reason":"Interactive mapping backend","package":"ipyleaflet","optional":false},{"reason":"Vue.js integration for widgets, pinned <1.12.0","package":"ipyvue","optional":false},{"reason":"Alternative mapping backend","package":"folium","optional":true}],"imports":[{"note":"Works but not idiomatic; direct import recommended","wrong":"import leafmap\nm = leafmap.Map()","symbol":"Map","correct":"from leafmap import Map"}],"quickstart":{"code":"from leafmap import Map\nm = Map()\nm.add_basemap('HYBRID')\nm","lang":"python","description":"Create an interactive map with a Google Hybrid basemap."},"warnings":[{"fix":"Use `from leafmap import Map`","message":"The `leafmap.leafmap` module is deprecated. Use `from leafmap import Map` instead of `from leafmap.leafmap import Map`.","severity":"deprecated","affected_versions":">=0.30.0"},{"fix":"Reinstall leafmap or downgrade ipyvue: `pip install ipyvue<1.12.0`","message":"In Google Colab, ipyvue must be pinned to <1.12.0 to avoid maplibre load failures. Leafmap now pins it automatically, but if you install other packages that upgrade ipyvue, you may break the map.","severity":"gotcha","affected_versions":">=0.61.1"},{"fix":"Upgrade leafmap to >=0.60.0","message":"The `leafmap.common` module was temporarily removed in v0.59.0 and restored in v0.60.0. If you used `from leafmap.common import *`, ensure you are on v0.60.0+.","severity":"breaking","affected_versions":"0.59.0"},{"fix":"Use `m.add_raster('file.tif', max_image_size=1000)`","message":"When using `Map.add_raster()`, large files may cause memory issues. Use `max_image_size` parameter or reproject to COG first.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-04-27T00:00:00.000Z","next_check":"2026-07-26T00:00:00.000Z","problems":[{"fix":"Use `from leafmap import Map` instead of `from leafmap.leafmap import Map`.","cause":"Removed in v0.30.0; the correct import is `from leafmap import Map`.","error":"ModuleNotFoundError: No module named 'leafmap.leafmap'"},{"fix":"Pass an integer: `m.add_raster('file.tif', max_image_size=1000)`","cause":"`add_raster()` expected a positive integer but received a float or non-positive integer.","error":"ValueError: The `max_image_size` must be a positive integer."}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}