Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-2210] Android: Crash on "the rest" test case ("unable to convert boolean")

GitHub Issuen/a
TypeBug
PriorityMedium
StatusClosed
ResolutionFixed
Resolution Date2011-04-17T01:58:25.000+0000
Affected Version/sn/a
Fix Version/sRelease 1.5.0 M05
ComponentsAndroid
Labelsandroid, android_refactor, crash, defect, regression
ReporterThomas Huelbert
AssigneeDon Thorp
Created2011-04-15T03:13:38.000+0000
Updated2011-04-17T01:58:25.000+0000

Description

G2 (2.2) some G1 (1.6) simulator (2.1) TiMobile SDK 1.5.0.add5e1

Crash on "the rest" test case
1.Controls>Text Field>The rest

results: crash on load.

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

Comments

  1. Don Thorp 2011-04-15

    The test was changed on line #112 to set a boolean to a value expecting an int.

       tf1.autocapitalization = true; // See autocorrect note
       

    not sure why that was done.

  2. Ralf Pfeiffer 2011-04-15

    I am asking Blain to take a look at iPhone side and modify the KS sample to be assigned an appropriate constant after checking the IOS source code and testing it.

  3. Jeff Haynie 2011-04-15

    (from [29db36375ebb62d2517509bfe08c839f08378031]) [#2210 state:fixed-in-qa] KS was incorrect; autocapitalization isn't like autocorrection. It's an integer, not a boolean. (iPhone was implicitly converting the boolean, which is why it didn't crash) https://github.com/appcelerator/titanium_mobile/commit/29db36375ebb62d2517509bfe08c839f08378031"> https://github.com/appcelerator/titanium_mobile/commit/29db36375ebb...

  4. Thomas Huelbert 2011-04-15

    crashes as of Titanium SDK version: 1.5.0 (12/10/10 08:19 f37ab6c) G2 (2.2)

    D/KrollContext( 5388): (kroll$10) [1416,36540] Running evaluated script: app://examples/textfield_therest.js
    D/dalvikvm( 5388): GC_FOR_MALLOC freed 12551 objects / 896680 bytes in 68ms
    D/AndroidRuntime( 5388): Shutting down VM
    W/dalvikvm( 5388): threadid=1: thread exiting with uncaught exception (group=0x4001d7e0)
    E/TiUncaughtHandler( 5388): (main) [284,36824] Sending event: exception on thread: main msg:java.lang.NumberFormatException: Unable to convert java.lang.Boolean; Titanium 1.5.0,2010/12/10 08:19,37ab6c
    E/TiUncaughtHandler( 5388): java.lang.NumberFormatException: Unable to convert java.lang.Boolean
    E/TiUncaughtHandler( 5388): at org.appcelerator.titanium.util.TiConvert.toInt(TiConvert.java:221)
    E/TiUncaughtHandler( 5388): at org.appcelerator.titanium.util.TiConvert.toInt(TiConvert.java:225)
    E/TiUncaughtHandler( 5388): at ti.modules.titanium.ui.widget.TiUIText.handleKeyboard(TiUIText.java:287)
    E/TiUncaughtHandler( 5388): at ti.modules.titanium.ui.widget.TiUIText.propertyChanged(TiUIText.java:185)
    E/TiUncaughtHandler( 5388): at org.appcelerator.kroll.KrollPropertyChange.fireEvent(KrollPropertyChange.java:21)
    E/TiUncaughtHandler( 5388): at org.appcelerator.kroll.KrollProxy.handleMessage(KrollProxy.java:431)
    E/TiUncaughtHandler( 5388): at org.appcelerator.titanium.proxy.TiViewProxy.handleMessage(TiViewProxy.java:269)
    E/TiUncaughtHandler( 5388): at android.os.Handler.dispatchMessage(Handler.java:95)
    E/TiUncaughtHandler( 5388): at android.os.Looper.loop(Looper.java:123)
    E/TiUncaughtHandler( 5388): at android.app.ActivityThread.main(ActivityThread.java:4627)
    E/TiUncaughtHandler( 5388): at java.lang.reflect.Method.invokeNative(Native Method)
    E/TiUncaughtHandler( 5388): at java.lang.reflect.Method.invoke(Method.java:521)
    E/TiUncaughtHandler( 5388): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
    E/TiUncaughtHandler( 5388): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
    E/TiUncaughtHandler( 5388): at dalvik.system.NativeStart.main(Native Method)

    back to Ralf

  5. Jeff Haynie 2011-04-15

    (from [feeaeaa52ebba42ee8b49ee235f6aa29a0e9cf31]) Guh [#2210 state:fixed-in-qa] Mea culpa; the last fix fixed Smoketest, not Kitchen Sink. That'll teach me to pay attention to paths. https://github.com/appcelerator/titanium_mobile/commit/feeaeaa52ebba42ee8b49ee235f6aa29a0e9cf31"> https://github.com/appcelerator/titanium_mobile/commit/feeaeaa52ebb...

  6. Thomas Huelbert 2011-04-15

    looking good RC2 ipod touch 4.2.1

JSON Source