Closed this-josh closed 10 months ago
FYI this is https://folium.streamlit.app/ currently
Scratch that, the docs are fine now, just down for a few minutes
By the way I've seen that you don't support 0.15.0
, note your requirements.txt
doesn't exclude 0.15.1
which might be your desired scenario.
If you don't want to support 0.15.x
change this folium>=0.13,!=0.15.0
to folium>=0.13,<0.15.0
By the way I've seen that you don't support 0.15.0, note your requirements.txt doesn't exclude 0.15.1 which might be your desired scenario.
No, that is the intended scenario. 0.15.0 of Folium made a change to its internals, which broke this package. 0.15.1 of Folium made a change that was intended to fix it, so we intended to support just that patch version and going forward.
However, the Folium change may have broken more than we expect, which might be what you are seeing with this functionality.
I'm not seeing that behavior on the draw page -- it seems to be working fine
Hm? Are you using a clean env with the same versions as I mentioned above?
I've recreated my env and still experience the issue on both Chrome and Safari
I can also reproduce it with streamlit-folium 0.17.1
But it the draw functionality works with
folium 0.14.0
streamlit 1.29.0
streamlit-folium 0.16.0
I also had a issues with the draw plugin and latest version of each packages (when drawing squares). I downgraded to folium 0.14 and streamlit-folium 0.16 and it works.
Interestingly the export button exports the correct data
Sorry about that @this-josh, I thought you meant that the drawing example was broken on https://folium.streamlit.app, which is what I was testing.
I have the same error. If it helps, in the browser console, I see this message:
index.tsx:137 Uncaught TypeError: Cannot read properties of undefined (reading 'toGeoJSON')
at onLayerClick (index.tsx:137:25)
at i.onDraw (index.tsx:108:10)
at i.fire (Events.js:190:11)
at i._fireCreatedEvent (leaflet.draw.js:8:3599)
at i._fireCreatedEvent (leaflet.draw.js:8:18428)
at i._onMouseUp (leaflet.draw.js:8:17214)
at i._onMouseUp (leaflet.draw.js:8:18039)
at c (DomEvent.js:92:13)
at Ut (DomEvent.Pointer.js:98:2)
at HTMLDocument.o [as _leaflet_touchendtouchend129_68] (DomEvent.Pointer.js:117:3)
Are you on streamlit_folium 0.17.4? This should be fixed.
Sorry I know I've raised a lot of tickets recently, I just believe it's good to raise them when found.
The draw example from your docs (they seem to be down currently so cannot link them)
Doesn't work with ^0.15.0 (I am using
0.15.1
specifically.After placing a marker it dones't deselect the tool, and the markers location is not updated in the output:
Versions
Thanks, Josh