python-visualization / folium

Python Data. Leaflet.js Maps.

Home Page:https://python-visualization.github.io/folium/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

raise Value Error('Custom files must have an attribution')

kananep opened this issue · comments

import folium

#assigning folium.Map to mapObj to create mapObj Object
mapObj = folium.Map(location=[6.694764, -1.631116], zoom_start=6 ,titles= 'Dtream Terrain')
mapObj.save('map2.html')

Output of folium.__version__

raise Value Error('Custom files must have an attribution')

I need help in fixing this issue , i check the folium.py and attribute code . I think there might be mistake in the code because after using the same template variable and the class requirement . I still get attribute error

I can't anything about a "Dtream Terrain" tileset. It doesn't seem like a tileset that's available in xyzservices. https://leaflet-extras.github.io/leaflet-providers/preview/

So Folium sees it as a custom tileset url, in which case an attribution also has to be provided. But that's not the real issue here, the real issue is that your tileset doesn't exist.

Please use an existing tileset from https://leaflet-extras.github.io/leaflet-providers/preview/ or provide a valid url with attribution.