printdotio / printio-ios-sdk

SDK that enables the printing of any photo, from any source, onto any product!
Other
20 stars 11 forks source link

iPad app crash after selecting product every time #525

Closed swervdev01 closed 7 years ago

swervdev01 commented 7 years ago

I have repeatedly successfully recreated this crash when using both an iPad simulator and real device. First, loading in one or more pictures using the following code:

var selectedImages = [UIImage]()
//add some images here to selectedImages ...
let photosMenuButton = PIOSideMenuButton(type: PIO_SM_PHONE)
let myMenuButton = PIOSideMenuButton(type: PIO_SM_PASSED_PHOTOS)
myMenuButton?.iconPath = Bundle.main.path(forResource: "AppIcon", ofType: "png")
myMenuButton?.title = "APPNAME"
let photoSources : NSMutableArray = NSMutableArray()
photoSources.add(photosMenuButton!)
photoSources.add(myMenuButton!)
let printIO = PrintIO(viewController: self, recipeId: "RECIPEID", isInTestMode: false);
printIO?.setAvailablePhotoSources(photoSources as [AnyObject])
printIO?.setImages(selectedImages)
printIO?.setCountryCode("US")
printIO?.open();

Upon opening the gooten interface, the user then selects any product and attempts to navigate to the photo picking screen. Have tested with the Coffee Mug and the Photo Album.

Error is shown below:

2016-12-07 23:10:55.852 APPNAME[38019:786602] Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Could not load NIB in bundle: 'NSBundle </PATH/TO/BUNDLE/Containers/Bundle/Application/PATH/TO/PRINTIO/APPNAME.app/PrintIOBundle.bundle> (not yet loaded)' with name 'VCSelectPhotos'' First throw call stack: ( 0 CoreFoundation 0x0000000110ab034b __exceptionPreprocess + 171 1 libobjc.A.dylib 0x000000011012a21e objc_exception_throw + 48 2 CoreFoundation 0x0000000110b19265 +[NSException raise:format:] + 197 3 UIKit 0x000000010e4b8bd2 -[UINib instantiateWithOwner:options:] + 507 4 UIKit 0x000000010e24cc21 -[UIViewController _loadViewFromNibNamed:bundle:] + 386 5 UIKit 0x000000010e24d543 -[UIViewController loadView] + 177 6 UIKit 0x000000010e24d878 -[UIViewController loadViewIfRequired] + 201 7 UIKit 0x000000010e254102 -[UIViewController viewWillAppear:] + 118 8 UIKit 0x000000010e27efbf -[UINavigationController _startCustomTransition:] + 1290 9 UIKit 0x000000010e28fc34 -[UINavigationController _startDeferredTransitionIfNeeded:] + 697 10 UIKit 0x000000010e290dc7 -[UINavigationController viewWillLayoutSubviews] + 58 11 UIKit 0x000000010e487d6f -[UILayoutContainerView layoutSubviews] + 223 12 UIKit 0x000000010e170f50 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 1237 13 QuartzCore 0x000000010db7dcc4 -[CALayer layoutSublayers] + 146 14 QuartzCore 0x000000010db71788 _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 366 15 QuartzCore 0x000000010db71606 _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 24 16 QuartzCore 0x000000010daff680 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 280 17 QuartzCore 0x000000010db2c767 _ZN2CA11Transaction6commitEv + 475 18 QuartzCore 0x000000010db2d0d7 _ZN2CA11Transaction17observer_callbackEP19CFRunLoopObservermPv + 113 19 CoreFoundation 0x0000000110a54e17 CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION + 23 20 CoreFoundation 0x0000000110a54d87 CFRunLoopDoObservers + 391 21 CoreFoundation 0x0000000110a39b9e __CFRunLoopRun + 1198 22 CoreFoundation 0x0000000110a39494 CFRunLoopRunSpecific + 420 23 GraphicsServices 0x0000000112c84a6f GSEventRunModal + 161 24 UIKit 0x000000010e0ac964 UIApplicationMain + 159 25 APPNAME 0x000000010949b47f main + 111 26 libdyld.dylib 0x0000000111be268d start + 1 ) libc++abi.dylib: terminating with uncaught exception of type NSException

perisicboro commented 7 years ago

Hi @swervdev01 sorry for late response.

SDK currently doesn't support Universal app mode, only iPhone. Are you using universal?