Closed fredonweb closed 5 years ago
Got the same issue... @fredonweb, do you have any updates?
I'm running into the same issue after months of it working just fine. I'm not using the markersNearAnyOtherMarker function explicitly in my code.
Here is where it is breaking for me in the marker-spiderfier.js file:
p.markerProximityData = function() { var i1, i2, l, len1, len2, m, m1, m1Data, m2, m2Data, mData, n, nDist, pxSq, ref1, ref2; if (this.projHelper.getProjection() == null) { throw "Must wait for 'idle' event on map before calling markersNearAnyOtherMarker"; }
The error is coming from line 364.
@johnvanhulsen were you able to find a workaround?
Hello,
I find my problem : some of my gps informations were coding with wrong decimal separator (comma instead dot). Stupid mistake !
Glad you fixed it!
Get the same error on every 5th load. @johnvanhulsen did you find the problem or a solution?
I am getting the same error sporadically as well.
I am using the library as instructed by the documentation and I am not doing anything weird. My map data is not malformed. I am using OMS in combination with markerclustererplus. When the issue happens, the effect is that spiderfied markers are not labeled as such, and look like normal markers. There could be other effects as well.
I only managed to avoid the issue by initializing the OMS library inside the map idle event handler. However, the markers are then displayed incorrectly - on top of the marker clusters, which are supposed to hide the markers.
I tried downgrading the maps library to version 3.27, as the documentation states it is somewhat more reliable, but that didn't help.
Hello
Same issue here.
I'm getting this too. It is sporadic.
In my case, I loaded OverlappingMarkerSpiderfier() when Google Map is loaded by:
google.maps.event.addListenerOnce(map, 'idle', function() { // do something only the first time the map is loaded oms = new OverlappingMarkerSpiderfier(map, {}); });
google.maps.event.addListenerOnce() will make sure Google Map is loaded, the original answer is from: https://stackoverflow.com/a/7262773/8801901
Hi,
I use this code for many months. All was ok. Since this week, my map doesn't work. I've this error code : "uncaught exception: Must wait for 'idle' event on map before calling markersNearAnyOtherMarker". I don't understand the problem.
Thanks for your help.