makinacorpus / django-leaflet

Use Leaflet in your Django projects
GNU Lesser General Public License v3.0
716 stars 282 forks source link

Broken Marker image paths in the Admin panel #382

Open andrew-plowright opened 1 month ago

andrew-plowright commented 1 month ago

Although this issue does not occur when DEBUG mode is on, in the production version of my app, the marker-icon.png image for point markers is broken.

image

image

If I'm not mistaken, instead of linking to just marker-icon.png, the correct path would be /static/leaflet/images/marker-icon.png.

I poked around and it sounds like this is a known issue with Whitenoise. This branch from @faaizajaz seems to have addressed it, although it is now four years old.

Here are the library versions I'm currently running:

django==5.0.4
django-extensions==3.2.3
django-debug-toolbar==4.3.0
djangorestframework==3.15.1
djangorestframework-gis==1.0
ipython==8.23.0
psycopg2-binary==2.9.9
dj_database_url==2.1.0
whitenoise==6.6.0
pandas==2.2.2
geopandas==0.14.3
openpyxl==3.1.2
xlsxwriter==3.2.0
django-leaflet==0.30.1
bleach==6.1.0
gunicorn==22.0.0