NSDataDetector fails on fractional street numbers such as 75 1/2
Originator: | greg | ||
Number: | rdar://45989903 | Date Originated: | 11/12/2018 |
Status: | Open | Resolved: | |
Product: | iOS + SDK | Product Version: | macOS 10.4.1 (18B75) running Xcode 10.1 (10B61) using stock iOS playground template |
Classification: | Crash/Hang/Data Loss | Reproducible: | Always |
Area: Contacts Framework Summary: NSDataDetector fails to parse fractional street addresses properly. Steps to Reproduce: The attached <https://smilesoftware.com/openradar/DataDetectorPlayground-iOS.playground.zip> Swift playground simulates an issue I encountered in the Mail app. Open the DataDetectorPlayground-iOS.playground file and run it. Expected Results: 75 1/2 Bedford St New York NY 10014 Actual Results: 1/2 Bedford St New York NY 10014 Version/Build: Xcode 10.1 (10B61) Configuration: macOS 10.4.1 (18B75) running Xcode 10.1 (10B61) using stock iOS playground template. Note: This is a legitimate address verified via usps.com. Attached <https://smilesoftware.com/openradar/USPS%20Bedford%20St%20Lookup.pdf>, please find the usps.com lookup result. Commentary: It's actually worse if you use ½ in place of 1/2. In that case, the result will be only: New York, NY 10014 …an even greater loss of data.
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!