Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-658] Problem with XHR + openPhotoGallery

GitHub Issuen/a
TypeBug
PriorityMedium
StatusClosed
ResolutionInvalid
Resolution Date2011-04-15T02:33:55.000+0000
Affected Version/sn/a
Fix Version/sRelease 1.2.0
ComponentsiOS
Labelsios, iphone, xhr
ReporterJeff Haynie
AssigneeReggie Seagraves
Created2011-04-15T02:33:54.000+0000
Updated2017-03-02T19:19:53.000+0000

Description

(From Kosso)

I've been stuck for a few days on an app crash in my app, which seems to always occur after choosing/taking photo or video or recording audio AFTER posting via XHR

My posting form is a window with tabBarHidden which opens the camera or media picker or opens my audio recorder.

It always works the first time perfectly, then uploads the media fine.

Then when I try to (in this example) openPhotoGallery, the app crashes with this stack trace output

[INFO] opening photo gallery....

2010-03-29 17:28:17.928 phreadz[26505:207] *** -[NSCFDictionary _tabBlur]: unrecognized selector sent to instance 0x5354f30

[ERROR] The application has crashed with an unhandled exception. Stack trace:

0 CoreFoundation 0x02bec45b raiseError + 299
1 libobjc.A.dylib 0x90417509 objc_exception_throw + 56
2 CoreFoundation 0x02c4983b -[NSObject doesNotRecognizeSelector:] + 187
3 CoreFoundation 0x02be0676
forwarding + 902
4 CoreFoundation 0x02bbc6c2 _CF_forwarding_prep_0 + 50
5 phreadz 0x0006f9cf -[TitaniumApp showModalController:animated:] + 83
6 phreadz 0x00091145 -[MediaModule openPhotoGallery:] + 575
7 Foundation 0x0048fb46
NSThreadPerformPerform + 678
8 CoreFoundation 0x02bb78e1 CFRunLoopRunSpecific + 3217
9 CoreFoundation 0x02bb6c48 CFRunLoopRunInMode + 88
10 GraphicsServices 0x02e8878d GSEventRunModal + 217
11 GraphicsServices 0x02e88852 GSEventRun + 115
12 UIKit 0x0071a003 UIApplicationMain + 1157
13 phreadz 0x0000264e main + 360
14 phreadz 0x000024ba start + 54

2010-03-29 17:28:17.930 phreadz[26505:207] Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: ' -[NSCFDictionary _tabBlur]: unrecognized selector sent to instance 0x5354f30'

2010-03-29 17:28:17.931 phreadz[26505:207] Stack: (
46056539,
2420208905,
46438459,
46007926,
45860546,
457167,
594245,
4782918,
45840609,
45837384,
48793485,
48793682,
7446531,
9806,
9402
)

[INFO] Application has exited from Simulator

Comments

  1. kosso 2011-04-15

    Hi,

    Just to add that this happens whenever I try to do anything related to the MediaModule (gallery, video, photo or record audio)

    And it always happens the SECOND time AFTER an XHR post.

    Unfortunately, I have not been able to replicate this with the KitchenSink XHR upload photo demo.
    I will see if I can create a simple replication of the bug and send it over.

    It's strange that the crash only occurs AFTER the XHR post.

  2. kosso 2011-04-15

    Here are some more console outputs after crashes:

    http://pastie.org/895357">http://pastie.org/895357

    I have also had this happen, again after an XHR POST when trying to open my audio recorder - so it seems that it's not totally related to the gallery or camera stuff.

    The common factor in every crash appears to be the '_tabBlur' - and it's always after an XHR POST to upload a TiBlob

    The crashes only when I actually click a button to open the gallery, record audio or use the camera. ie: nothing seems to crash on my actual post/form window

    I'm currently trying to strip down my posting window to see what it could be related to.

  3. kosso 2011-04-15

    Hi,

    Sorry. But you can ignore this now. Or change to 'invalid'

    It seems that I had been using some windows where I could have been using views and this was somehow confusing the window hierarchy after going back/closing a complex window with the media/camera launching button on it. this was causing the _tabBlur to get muddled.

    I have altered my designs to use just views and the issue seems to have gone away.

  4. Don Thorp 2011-04-15

    marked invalid as requested.

  5. Lee Morris 2017-03-02

    Closed as invalid.

JSON Source