question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Default Icon Failing to Show

See original GitHub issue

I’m trying to use the sample code

from ipyleaflet import Map, Marker

center = (52.204793, 360.121558)

m = Map(center=center, zoom=15)

marker = Marker(location=center, draggable=False)
m.add_layer(marker);

m

This shows the map, but no icon shows.

image

If I use a custom icon like this, it works:

from ipyleaflet import Marker, Icon, Map

center = (52.204793, 360.121558)

m = Map(center=center, zoom=10)
icon = Icon(icon_url='https://leafletjs.com/examples/custom-icons/leaf-green.png', icon_size=[38, 95], icon_anchor=[22,94])
mark = Marker(location=center, icon=icon, rotation_angle=90, rotation_origin='22px 94px')
m.add_layer(mark);

m

image

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
martinRenoucommented, Apr 23, 2020

Should be fixed by #552

1reaction
doug-olcommented, Apr 15, 2020

Yes Yes this is what I see in the Chrome Debugger.

[object%20Module]:1 GET http://localhost:8889/[object%20Module] 404 (Not Found)
Image (async)
_createImg @ leaflet-src.js:7170
_createIcon @ leaflet-src.js:7137
createIcon @ leaflet-src.js:7118
_initIcon @ leaflet-src.js:7593
_initIcon @ leaflet.rotatedMarker.js:23
onAdd @ leaflet-src.js:7500
_layerAdd @ leaflet-src.js:6617
whenReady @ leaflet-src.js:4477
addLayer @ leaflet-src.js:6679
(anonymous) @ Map.js:140
Promise.then (async)
add_layer_model @ Map.js:139
e.update @ viewlist.js:54
(anonymous) @ Map.js:195
Promise.then (async)
render_leaflet @ Map.js:194
Promise.then (async)
render @ Map.js:190
(anonymous) @ manager-base.js:93
Promise.then (async)
(anonymous) @ manager-base.js:87
Promise.then (async)
e.create_view @ manager-base.js:86
e.display_model @ manager-base.js:73
renderModel @ renderer.js:56
async function (async)
renderModel @ renderer.js:30
createRenderedMimetype @ widget.js:429
createOutputItem @ widget.js:401
_insertOutput @ widget.js:384
onModelChanged @ widget.js:216
m @ index.js:478
c @ index.js:435
e.emit @ index.js:108
_onListChanged @ model.js:231
m @ index.js:478
c @ index.js:435
e.emit @ index.js:108
push @ observablelist.js:135
_add @ model.js:207
add @ model.js:128
_onIOPub @ widget.js:91
_handleIOPub @ future.js:216
async function (async)
_handleIOPub @ future.js:212
handleMsg @ future.js:186
_handleMessage @ default.js:1087
(anonymous) @ default.js:94
Promise.then (async)
_onWSMessage @ default.js:91
Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Fix Broken or Missing Icons and Thumbnails in ...
Are your desktop icons and image thumbnails not displaying correctly? Here is a way you can fix them in Windows 10.
Read more >
Desktop Icons Not Showing Up - Driver Support
If it's just the default (system) icons you seek, right-click the desktop and choose Personalize. Go into Themes and select Desktop icon settings....
Read more >
How to Fix Blank Icons in Windows 10 - Help Desk Geek
1. Press Ctrl + Shift + Esc to open the Task Manager. ; 2. Select More details to expand the default Task Manager...
Read more >
Issue with Default Image Icons. - Microsoft Community
Open the file explorer page to see the icons of the pictures. b. Click on View in the ribbon and select Large Icons....
Read more >
FIXED: Desktop Icons Not Showing Properly In Win 8,8.1,10
Once done implementing this easy fix, Windows rebuilds the icon cache and you would be able to see all the icons as they...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found