Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

On clicking a marker, event handling leads to KeyError: (-34.67698205588844, 139.24381256103518) not found in the marker_info property #2

Open
jmp75 opened this issue Jun 13, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@jmp75
Copy link
Owner

jmp75 commented Jun 13, 2024

Environment Information

  • ipyleaflet_dashboard_tools version: 2024-06-13

Description

Trying to explore time series of streafmlw over the murray-darling basin

In some circumstances if two locations are very nearby the on_click event does not return the exact coordinates that were sourced in the xarray data. The on_click event handler fails to locate the coordinates in the marker_info dictionary. For instance clicking on one of the markers for two stations very close:

[((-34.6743, 139.2319), 'A4260529'), ((-34.6741, 139.2317), 'A4260605')]

and the lat/lon are exact, not rounded approximations

the jupyter output console reports the exception:

KeyError: (-34.67698205588844, 139.24381256103518)

The markers for these two stations are displaied apart with an arrow to the real location, to show them apart. However I suspect the event arguments are using the display coordinates, not the coordinates of the streamflow station.

I initially thought I had a case of duplicate lat/lon, but this is more complicated than this.

@jmp75 jmp75 added the bug Something isn't working label Jun 13, 2024
@jmp75
Copy link
Owner Author

jmp75 commented Jun 13, 2024

Even at max zoom one needs to click on the cluster to have two markers displayed:
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant