MapKit: callouts are not always removed when an annotation view is re-used

Originator:robotspacer
Number:rdar://19493144 Date Originated:15-Jan-2015 08:04 PM
Status:Open Resolved:
Product:OS X SDK Product Version:OS X 10.10.1 (14B25) and Xcode 6.1.1 (6A2008a). The bug is also present in 10.10.2 (14C99d).
Classification:UI/Usability Reproducible:Sometimes
 
Summary:
My app Deliveries will drop a pin on the map, zoom into that area, then show the callout for that pin. If a different item is selected, existing pins are removed, and the same sequence happens again in a different location. If the timing is just right, the re-used annotation view will still have a callout visible from the previous item. I *think* the important thing in triggering the bug is to remove the annotation while the callout is still animating in.

Steps to Reproduce:
1. Run the attached project.
2. Click the "Drop Pin" button.

Expected Results:
Only one callout should be visible. Clicking elsewhere on the map should dismiss it.

Actual Results:
Often there are two, and only one can be dismissed. Sometimes you may see one callout to the left of the pin and one on the right. Sometimes they are directly on top of each other.

Version:
OS X 10.10.1 (14B25) and Xcode 6.1.1 (6A2008a). The bug is also present in 10.10.2 (14C99d).

Notes:
The attachment includes a screenshot showing one result of this bug, along with the sample project.

I'm not sure how much code is shared, but a very similar bug exists in iOS 8 as well. My iOS bug report is rdar://19507725

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!