agens-no / AGGeometryKit

Quadrilaterals on CALayer, CGGeometry-functions, UIView/CALayer properties and other invaluable tools.
Other
1.27k stars 130 forks source link

Demo Quad Example Crashes with Xcode 6 Beta and Simulator #13

Closed snown closed 10 years ago

snown commented 10 years ago

Firstly, I would like to state that I understand that this issue is in the Xcode beta, and therefore should be treated as low priority. I did check that this issue does not occur in Xcode 5 with the iOS 7.1 Simulator.

That being said I am experiencing an issue with Xcode 6 and the iOS 8 Simulator and the quad demo where dragging from any corner other than the upper left results in a crash. Here's what I'm seeing: screenshot 2014-06-11 17 30 40

And the console in text:

2014-06-11 17:30:17.257 AGGeometryKit[14762:346482] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[__NSSetM addObject:]: object cannot be nil'
*** First throw call stack:
(
    0   CoreFoundation                      0x01e1b916 __exceptionPreprocess + 182
    1   libobjc.A.dylib                     0x01ab98d9 objc_exception_throw + 44
    2   CoreFoundation                      0x01d3152b -[__NSSetM addObject:] + 699
    3   UIKit                               0x0032570c _UIApplicationHandleEventFromQueueEvent + 1522
    4   UIKit                               0x002feb64 _UIApplicationHandleEventQueue + 1561
    5   CoreFoundation                      0x01d4030f __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 15
    6   CoreFoundation                      0x01d34c99 __CFRunLoopDoSources0 + 249
    7   CoreFoundation                      0x01d341f8 __CFRunLoopRun + 952
    8   CoreFoundation                      0x01d33b7b CFRunLoopRunSpecific + 443
    9   CoreFoundation                      0x01d339ab CFRunLoopRunInMode + 123
    10  GraphicsServices                    0x03922500 GSEventRunModal + 192
    11  GraphicsServices                    0x0392233d GSEventRun + 104
    12  UIKit                               0x00302dee UIApplicationMain + 3727
    13  AGGeometryKit                       0x0000b11c main + 76
    14  libdyld.dylib                       0x034a9ac5 start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException

Dragging from the upper left handle seemed to work. Additionally all of the other demos seemed to work.

Thanks for taking a look, please let me know if I can provide any more information, or help out in any way.

hfossli commented 10 years ago

Thank you for submitting a great and informative bug report! I will look into this issue next week. If you happen to find the cause for the bug you are welcome to create a pulll request. Thanks!

alex-hofsteede commented 10 years ago

@hfossli Any insights on this? I believe I am seeing the same thing.

hfossli commented 10 years ago

Will look into it on friday probably. Pull requests is welcome!

alex-hofsteede commented 10 years ago

@hfossli I've just been trying some things, and moving to iOS SDK 8.0 beta 2 (Xcode 6 beta 2) seems to fix this. I can't find anything in the release notes that specifically mentions it being fixed, but it hasn't happened since I upgraded.

hfossli commented 10 years ago

Great to know! It may be related to my code, but it seems more related to how UIKit is handling touch. I am not using any addObject: method on NSSet. If someone reports this problem on the beta 2 or higher I will definitely look into it.

snown commented 10 years ago

I can confirm that this issue is no longer presenting itself in later beta versions of Xcode 6. Feel free to close.

hfossli commented 10 years ago

Thanks