Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-8516] iOS: UI.View: intermittent deadlock warning

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2012-07-09T04:52:35.000+0000
Affected Version/sRelease 2.1.0
Fix Version/sRelease 2.1.0
ComponentsiOS
Labelsmodule_views, qe-testadded
ReporterDustin Hyde
AssigneeStephen Tramer
Created2012-04-04T14:12:59.000+0000
Updated2013-11-05T10:12:23.000+0000

Description

When running the code below, a deadlock warning intermittently appears: Apr 4 14:59:27 unknown UIKitApplication:com.appcelerator.timob8193[0x13cc][3489] : [WARN] Timing out waiting on main thread. Possibly a deadlock? in TiThreadPerformOnMainThread (TiBase.m:238) Attempted to reproduce in 2.0.0.GA, but could not. Steps to Reproduce: 1. Run code.
var win1 = Ti.UI.createWindow({  
    title:'Win 1',
    layout:'vertical',
    backgroundColor:'#fff'
});
 
var vw1 = Ti.UI.createView({
    layout:'horizontal',
    backgroundColor:'red',
    width:'100%',
    height:75
});
win1.add(vw1);
 
//
var TheOrange=Ti.UI.createView({height:75,
                                width:'160dp',
                                backgroundColor:'orange',
                                top:0
                               });
 
var GreenView=Ti.UI.createView({
          height:Ti.UI.SIZE,
          width:Ti.UI.SIZE,
          focusable:false,
          touchEnabled:false,
          backgroundColor:'green'
});
 
GreenView.add(TheOrange);
vw1.add(GreenView);
 
var BlueView=Ti.UI.createView({
    backgroundColor:'blue',
    width:50,
    height:50
});
vw1.add(BlueView);
//
 
win1.open();
Expected Result: Views should appear without deadlock warnings. Actual Result: Views appear with deadlock warning, intermittent.

Comments

  1. James K 2012-04-06

    I receive the same warning when running a newly-built module for iOS (generated as per the modules guide using 2.1.0, without making any changes or additions): [WARN] Timing out waiting on main thread. Possibly a deadlock? in TiThreadPerformOnMainThread (TiBase.m:238)
  2. Tyler Golden 2012-04-10

    I received the same warning when using a table within a standard window. Appears intermittently in a few other places as well.
  3. stefano di luca 2012-05-06

    Same problem when running on iPad [DEBUG] application booted in 553.596020 ms [WARN] Timing out waiting on main thread. Possibly a deadlock? in TiThreadPerformOnMainThread (TiBase.m:238) The app is only showing a white screen or the splash screen. Sometimes my index.js file is loaded after waiting 2-3 minutes for the splash screen but the app is not responding/loading completely.
  4. Mark Anthony Sabandal 2012-06-11

    I am also experiencing this issue after using 2.0.2GA SDK from 1.8.2. Our app takes more time to start than before and its having this error message. {quote} 2012-06-12 10:28:59.104 What Happen[88198:207] -[UITabBarController setSelectedViewController:] only a view controller in the tab bar controller's list of view controllers can be selected. [WARN] Timing out waiting on main thread. Possibly a deadlock? in TiThreadPerformOnMainThread (TiBase.m:238) {quote}
  5. Ian Tearle 2012-06-14

    Am also receiving this error. More than what could be classed as intermittently too. Does any one know if this will prevent app store submission?
  6. Stephen Tramer 2012-06-14

    These warnings have been removed from production builds in 2.1.0. They are only useful for internal developers.
  7. Tamila Smolich 2012-06-26

    Closing as fixed. Tested and verified with: Titanium Studio, build: 2.1.0.201206251749 Titanium SDK: 2.1.0.v20120626104306 Device: iPad 3rd gen (5.1.1) Views appear without deadlock warnings.
  8. Neha Chhabra 2012-07-09

    Reopening to update labels.

JSON Source