android.view.WindowLeaked: Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@409094d0 that was originally added here

Appcelerator JIRA | Eric Merriman | 5 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Decription: While testing Kitchen Sink I launched Platform > Platform Data. After reviewing the content I tapped "back". I saw a flash of a runtime error and console output indicated errors and a leaked window. We were able to verify that this does not occur in the Kitchen Sink from the titanium_mobile GIT repo. It only occurs with the sample, and also occurs with the sample using SDK 1.8.0.1. Console output for V8: {code} E/TiJSError( 1756): (main) [13813,1878551] ----- Titanium Javascript Runtime Error ----- E/TiJSError( 1756): (main) [0,1878551] - In ti:/events.js:201,10 E/TiJSError( 1756): (main) [1,1878552] - Message: Uncaught Error: removeListener only takes instances of Function E/TiJSError( 1756): (main) [0,1878552] - Source: throw new Error('removeListener only takes instances of Function'); E/V8Exception( 1756): Exception occurred at ti:/events.js:201: Uncaught Error: removeListener only takes instances of Function E/TiBaseActivity( 1756): (main) [1077,1879629] Layout cleanup. E/WindowManager( 1756): Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@44adf870 that was originally added here E/WindowManager( 1756): android.view.WindowLeaked: Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@44adf870 that was originally added here E/WindowManager( 1756): at android.view.ViewRoot.<init>(ViewRoot.java:247) E/WindowManager( 1756): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:148) E/WindowManager( 1756): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:91) E/WindowManager( 1756): at android.view.Window$LocalWindowManager.addView(Window.java:424) E/WindowManager( 1756): at android.app.Dialog.show(Dialog.java:241) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiJSErrorDialog.createDialog(TiJSErrorDialog.java:204) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiJSErrorDialog$1.onCurrentActivityReady(TiJSErrorDialog.java:104) E/WindowManager( 1756): at org.appcelerator.titanium.util.TiUIHelper.waitForCurrentActivity(TiUIHelper.java:154) E/WindowManager( 1756): at org.appcelerator.titanium.TiApplication.waitForCurrentActivity(TiApplication.java:702) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiJSErrorDialog.handleOpenErrorDialog(TiJSErrorDialog.java:99) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiJSErrorDialog.handleMessage(TiJSErrorDialog.java:226) E/WindowManager( 1756): at android.os.Handler.dispatchMessage(Handler.java:95) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiMessenger.dispatchMessage(TiMessenger.java:318) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiMessenger.dispatchPendingMessages(TiMessenger.java:303) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiMessenger$2.getResult(TiMessenger.java:188) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiMessenger.sendBlockingMessage(TiMessenger.java:215) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiMessenger.sendBlockingRuntimeMessage(TiMessenger.java:143) E/WindowManager( 1756): at org.appcelerator.kroll.KrollProxy.fireSyncEvent(KrollProxy.java:417) E/WindowManager( 1756): at org.appcelerator.titanium.TiBaseActivity.finish(TiBaseActivity.java:831) E/WindowManager( 1756): at android.app.Activity.onBackPressed(Activity.java:1910) E/WindowManager( 1756): at android.app.Activity.onKeyUp(Activity.java:1888) E/WindowManager( 1756): at android.view.KeyEvent.dispatch(KeyEvent.java:1061) E/WindowManager( 1756): at android.app.Activity.dispatchKeyEvent(Activity.java:2068) E/WindowManager( 1756): at org.appcelerator.titanium.TiBaseActivity.dispatchKeyEvent(TiBaseActivity.java:513) E/WindowManager( 1756): at com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchKeyEvent(PhoneWindow.java:1643) E/WindowManager( 1756): at android.view.ViewRoot.deliverKeyEventToViewHierarchy(ViewRoot.java:2471) E/WindowManager( 1756): at android.view.ViewRoot.handleFinishedEvent(ViewRoot.java:2441) E/WindowManager( 1756): at android.view.ViewRoot.handleMessage(ViewRoot.java:1735) E/WindowManager( 1756): at android.os.Handler.dispatchMessage(Handler.java:99) E/WindowManager( 1756): at android.os.Looper.loop(Looper.java:123) E/WindowManager( 1756): at android.app.ActivityThread.main(ActivityThread.java:4627) E/WindowManager( 1756): at java.lang.reflect.Method.invokeNative(Native Method) E/WindowManager( 1756): at java.lang.reflect.Method.invoke(Method.java:521) E/WindowManager( 1756): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:858) E/WindowManager( 1756): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616) E/WindowManager( 1756): at dalvik.system.NativeStart.main(Native Method) {code} Console output for Rhino: {code} E/RhinoObject( 2025): (KrollRuntimeThread) [13577,1727390] Error: removeListener only takes instances of Function (/tmp/events.js#201) E/RhinoObject( 2025): org.mozilla.javascript.JavaScriptException: Error: removeListener only takes instances of Function (/tmp/events.js#201) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events._c_anonymous_8(/tmp/events.js:200) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events.call(/tmp/events.js) E/RhinoObject( 2025): at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:1701) E/RhinoObject( 2025): at script(examples/platform.js:14) E/RhinoObject( 2025): at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:854) E/RhinoObject( 2025): at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:164) E/RhinoObject( 2025): at org.mozilla.javascript.optimizer.OptRuntime.callName(OptRuntime.java:97) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.window._c_anonymous_30(/tmp/window.js:463) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.window.call(/tmp/window.js) E/RhinoObject( 2025): at org.mozilla.javascript.ScriptRuntime.applyOrCall(ScriptRuntime.java:2520) E/RhinoObject( 2025): at org.mozilla.javascript.BaseFunction.execIdCall(BaseFunction.java:300) E/RhinoObject( 2025): at org.mozilla.javascript.IdFunctionObject.call(IdFunctionObject.java:129) E/RhinoObject( 2025): at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:76) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events._c_anonymous_2(/tmp/events.js:42) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events.call(/tmp/events.js) E/RhinoObject( 2025): at org.mozilla.javascript.optimizer.OptRuntime.callN(OptRuntime.java:86) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events._c_anonymous_3(/tmp/events.js:85) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events.call(/tmp/events.js) E/RhinoObject( 2025): at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:426) E/RhinoObject( 2025): at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3177) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events.call(/tmp/events.js) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.RhinoObject.fireEvent(RhinoObject.java:73) E/RhinoObject( 2025): at org.appcelerator.kroll.KrollProxy.doFireEvent(KrollProxy.java:441) E/RhinoObject( 2025): at org.appcelerator.kroll.KrollProxy.handleMessage(KrollProxy.java:608) E/RhinoObject( 2025): at org.appcelerator.titanium.proxy.TiViewProxy.handleMessage(TiViewProxy.java:347) E/RhinoObject( 2025): at org.appcelerator.titanium.proxy.TiWindowProxy.handleMessage(TiWindowProxy.java:109) E/RhinoObject( 2025): at ti.modules.titanium.ui.ActivityWindowProxy.handleMessage(ActivityWindowProxy.java:94) E/RhinoObject( 2025): at android.os.Handler.dispatchMessage(Handler.java:95) E/RhinoObject( 2025): at android.os.Looper.loop(Looper.java:130) E/RhinoObject( 2025): at org.appcelerator.kroll.KrollRuntime$KrollRuntimeThread.run(KrollRuntime.java:102) E/TiJSError( 2025): (main) [90,1727480] ----- Titanium Javascript Runtime Error ----- E/TiJSError( 2025): (main) [1,1727481] - In /tmp/events.js:201,0 E/TiJSError( 2025): (main) [2,1727483] - Message: Error: removeListener only takes instances of Function (/tmp/events.js#201) E/TiJSError( 2025): (main) [1,1727484] - Source: null E/TiBaseActivity( 2025): (main) [257,1727741] Layout cleanup. E/WindowManager( 2025): Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@409094d0 that was originally added here E/WindowManager( 2025): android.view.WindowLeaked: Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@409094d0 that was originally added here E/WindowManager( 2025): at android.view.ViewRoot.<init>(ViewRoot.java:258) E/WindowManager( 2025): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:148) E/WindowManager( 2025): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:91) E/WindowManager( 2025): at android.view.Window$LocalWindowManager.addView(Window.java:424) E/WindowManager( 2025): at android.app.Dialog.show(Dialog.java:241) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiJSErrorDialog.createDialog(TiJSErrorDialog.java:204) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiJSErrorDialog$1.onCurrentActivityReady(TiJSErrorDialog.java:104) E/WindowManager( 2025): at org.appcelerator.titanium.util.TiUIHelper.waitForCurrentActivity(TiUIHelper.java:154) E/WindowManager( 2025): at org.appcelerator.titanium.TiApplication.waitForCurrentActivity(TiApplication.java:702) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiJSErrorDialog.handleOpenErrorDialog(TiJSErrorDialog.java:99) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiJSErrorDialog.handleMessage(TiJSErrorDialog.java:226) E/WindowManager( 2025): at android.os.Handler.dispatchMessage(Handler.java:95) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiMessenger.dispatchMessage(TiMessenger.java:318) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiMessenger.dispatchPendingMessages(TiMessenger.java:303) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiMessenger$2.getResult(TiMessenger.java:188) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiMessenger.sendBlockingMessage(TiMessenger.java:215) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiMessenger.sendBlockingRuntimeMessage(TiMessenger.java:143) E/WindowManager( 2025): at org.appcelerator.kroll.KrollProxy.fireSyncEvent(KrollProxy.java:417) E/WindowManager( 2025): at org.appcelerator.titanium.TiBaseActivity.finish(TiBaseActivity.java:831) E/WindowManager( 2025): at android.app.Activity.onBackPressed(Activity.java:1920) E/WindowManager( 2025): at android.app.Activity.onKeyUp(Activity.java:1898) E/WindowManager( 2025): at android.view.KeyEvent.dispatch(KeyEvent.java:1280) E/WindowManager( 2025): at android.app.Activity.dispatchKeyEvent(Activity.java:2078) E/WindowManager( 2025): at org.appcelerator.titanium.TiBaseActivity.dispatchKeyEvent(TiBaseActivity.java:513) E/WindowManager( 2025): at com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchKeyEvent(PhoneWindow.java:1663) E/WindowManager( 2025): at android.view.ViewRoot.deliverKeyEventToViewHierarchy(ViewRoot.java:2560) E/WindowManager( 2025): at android.view.ViewRoot.handleFinishedEvent(ViewRoot.java:2535) E/WindowManager( 2025): at android.view.ViewRoot.handleMessage(ViewRoot.java:1867) E/WindowManager( 2025): at android.os.Handler.dispatchMessage(Handler.java:99) E/WindowManager( 2025): at android.os.Looper.loop(Looper.java:130) E/WindowManager( 2025): at android.app.ActivityThread.main(ActivityThread.java:3683) E/WindowManager( 2025): at java.lang.reflect.Method.invokeNative(Native Method) E/WindowManager( 2025): at java.lang.reflect.Method.invoke(Method.java:507) E/WindowManager( 2025): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839) E/WindowManager( 2025): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597) E/WindowManager( 2025): at dalvik.system.NativeStart.main(Native Method) {code} Steps to reproduce: 1) Install KS from sample pane in Studio 1.0.8 2) Navigate to Platform > Platform Data 3) Press "back" Result: Runtime error and leaked window Expected: No runtime error, no leaked windows

    Appcelerator JIRA | 5 years ago | Eric Merriman
    android.view.WindowLeaked: Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@409094d0 that was originally added here
  2. 0

    Decription: While testing Kitchen Sink I launched Platform > Platform Data. After reviewing the content I tapped "back". I saw a flash of a runtime error and console output indicated errors and a leaked window. We were able to verify that this does not occur in the Kitchen Sink from the titanium_mobile GIT repo. It only occurs with the sample, and also occurs with the sample using SDK 1.8.0.1. Console output for V8: {code} E/TiJSError( 1756): (main) [13813,1878551] ----- Titanium Javascript Runtime Error ----- E/TiJSError( 1756): (main) [0,1878551] - In ti:/events.js:201,10 E/TiJSError( 1756): (main) [1,1878552] - Message: Uncaught Error: removeListener only takes instances of Function E/TiJSError( 1756): (main) [0,1878552] - Source: throw new Error('removeListener only takes instances of Function'); E/V8Exception( 1756): Exception occurred at ti:/events.js:201: Uncaught Error: removeListener only takes instances of Function E/TiBaseActivity( 1756): (main) [1077,1879629] Layout cleanup. E/WindowManager( 1756): Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@44adf870 that was originally added here E/WindowManager( 1756): android.view.WindowLeaked: Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@44adf870 that was originally added here E/WindowManager( 1756): at android.view.ViewRoot.<init>(ViewRoot.java:247) E/WindowManager( 1756): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:148) E/WindowManager( 1756): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:91) E/WindowManager( 1756): at android.view.Window$LocalWindowManager.addView(Window.java:424) E/WindowManager( 1756): at android.app.Dialog.show(Dialog.java:241) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiJSErrorDialog.createDialog(TiJSErrorDialog.java:204) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiJSErrorDialog$1.onCurrentActivityReady(TiJSErrorDialog.java:104) E/WindowManager( 1756): at org.appcelerator.titanium.util.TiUIHelper.waitForCurrentActivity(TiUIHelper.java:154) E/WindowManager( 1756): at org.appcelerator.titanium.TiApplication.waitForCurrentActivity(TiApplication.java:702) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiJSErrorDialog.handleOpenErrorDialog(TiJSErrorDialog.java:99) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiJSErrorDialog.handleMessage(TiJSErrorDialog.java:226) E/WindowManager( 1756): at android.os.Handler.dispatchMessage(Handler.java:95) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiMessenger.dispatchMessage(TiMessenger.java:318) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiMessenger.dispatchPendingMessages(TiMessenger.java:303) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiMessenger$2.getResult(TiMessenger.java:188) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiMessenger.sendBlockingMessage(TiMessenger.java:215) E/WindowManager( 1756): at org.appcelerator.kroll.common.TiMessenger.sendBlockingRuntimeMessage(TiMessenger.java:143) E/WindowManager( 1756): at org.appcelerator.kroll.KrollProxy.fireSyncEvent(KrollProxy.java:417) E/WindowManager( 1756): at org.appcelerator.titanium.TiBaseActivity.finish(TiBaseActivity.java:831) E/WindowManager( 1756): at android.app.Activity.onBackPressed(Activity.java:1910) E/WindowManager( 1756): at android.app.Activity.onKeyUp(Activity.java:1888) E/WindowManager( 1756): at android.view.KeyEvent.dispatch(KeyEvent.java:1061) E/WindowManager( 1756): at android.app.Activity.dispatchKeyEvent(Activity.java:2068) E/WindowManager( 1756): at org.appcelerator.titanium.TiBaseActivity.dispatchKeyEvent(TiBaseActivity.java:513) E/WindowManager( 1756): at com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchKeyEvent(PhoneWindow.java:1643) E/WindowManager( 1756): at android.view.ViewRoot.deliverKeyEventToViewHierarchy(ViewRoot.java:2471) E/WindowManager( 1756): at android.view.ViewRoot.handleFinishedEvent(ViewRoot.java:2441) E/WindowManager( 1756): at android.view.ViewRoot.handleMessage(ViewRoot.java:1735) E/WindowManager( 1756): at android.os.Handler.dispatchMessage(Handler.java:99) E/WindowManager( 1756): at android.os.Looper.loop(Looper.java:123) E/WindowManager( 1756): at android.app.ActivityThread.main(ActivityThread.java:4627) E/WindowManager( 1756): at java.lang.reflect.Method.invokeNative(Native Method) E/WindowManager( 1756): at java.lang.reflect.Method.invoke(Method.java:521) E/WindowManager( 1756): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:858) E/WindowManager( 1756): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616) E/WindowManager( 1756): at dalvik.system.NativeStart.main(Native Method) {code} Console output for Rhino: {code} E/RhinoObject( 2025): (KrollRuntimeThread) [13577,1727390] Error: removeListener only takes instances of Function (/tmp/events.js#201) E/RhinoObject( 2025): org.mozilla.javascript.JavaScriptException: Error: removeListener only takes instances of Function (/tmp/events.js#201) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events._c_anonymous_8(/tmp/events.js:200) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events.call(/tmp/events.js) E/RhinoObject( 2025): at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:1701) E/RhinoObject( 2025): at script(examples/platform.js:14) E/RhinoObject( 2025): at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:854) E/RhinoObject( 2025): at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:164) E/RhinoObject( 2025): at org.mozilla.javascript.optimizer.OptRuntime.callName(OptRuntime.java:97) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.window._c_anonymous_30(/tmp/window.js:463) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.window.call(/tmp/window.js) E/RhinoObject( 2025): at org.mozilla.javascript.ScriptRuntime.applyOrCall(ScriptRuntime.java:2520) E/RhinoObject( 2025): at org.mozilla.javascript.BaseFunction.execIdCall(BaseFunction.java:300) E/RhinoObject( 2025): at org.mozilla.javascript.IdFunctionObject.call(IdFunctionObject.java:129) E/RhinoObject( 2025): at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:76) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events._c_anonymous_2(/tmp/events.js:42) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events.call(/tmp/events.js) E/RhinoObject( 2025): at org.mozilla.javascript.optimizer.OptRuntime.callN(OptRuntime.java:86) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events._c_anonymous_3(/tmp/events.js:85) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events.call(/tmp/events.js) E/RhinoObject( 2025): at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:426) E/RhinoObject( 2025): at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3177) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.js.events.call(/tmp/events.js) E/RhinoObject( 2025): at org.appcelerator.kroll.runtime.rhino.RhinoObject.fireEvent(RhinoObject.java:73) E/RhinoObject( 2025): at org.appcelerator.kroll.KrollProxy.doFireEvent(KrollProxy.java:441) E/RhinoObject( 2025): at org.appcelerator.kroll.KrollProxy.handleMessage(KrollProxy.java:608) E/RhinoObject( 2025): at org.appcelerator.titanium.proxy.TiViewProxy.handleMessage(TiViewProxy.java:347) E/RhinoObject( 2025): at org.appcelerator.titanium.proxy.TiWindowProxy.handleMessage(TiWindowProxy.java:109) E/RhinoObject( 2025): at ti.modules.titanium.ui.ActivityWindowProxy.handleMessage(ActivityWindowProxy.java:94) E/RhinoObject( 2025): at android.os.Handler.dispatchMessage(Handler.java:95) E/RhinoObject( 2025): at android.os.Looper.loop(Looper.java:130) E/RhinoObject( 2025): at org.appcelerator.kroll.KrollRuntime$KrollRuntimeThread.run(KrollRuntime.java:102) E/TiJSError( 2025): (main) [90,1727480] ----- Titanium Javascript Runtime Error ----- E/TiJSError( 2025): (main) [1,1727481] - In /tmp/events.js:201,0 E/TiJSError( 2025): (main) [2,1727483] - Message: Error: removeListener only takes instances of Function (/tmp/events.js#201) E/TiJSError( 2025): (main) [1,1727484] - Source: null E/TiBaseActivity( 2025): (main) [257,1727741] Layout cleanup. E/WindowManager( 2025): Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@409094d0 that was originally added here E/WindowManager( 2025): android.view.WindowLeaked: Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@409094d0 that was originally added here E/WindowManager( 2025): at android.view.ViewRoot.<init>(ViewRoot.java:258) E/WindowManager( 2025): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:148) E/WindowManager( 2025): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:91) E/WindowManager( 2025): at android.view.Window$LocalWindowManager.addView(Window.java:424) E/WindowManager( 2025): at android.app.Dialog.show(Dialog.java:241) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiJSErrorDialog.createDialog(TiJSErrorDialog.java:204) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiJSErrorDialog$1.onCurrentActivityReady(TiJSErrorDialog.java:104) E/WindowManager( 2025): at org.appcelerator.titanium.util.TiUIHelper.waitForCurrentActivity(TiUIHelper.java:154) E/WindowManager( 2025): at org.appcelerator.titanium.TiApplication.waitForCurrentActivity(TiApplication.java:702) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiJSErrorDialog.handleOpenErrorDialog(TiJSErrorDialog.java:99) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiJSErrorDialog.handleMessage(TiJSErrorDialog.java:226) E/WindowManager( 2025): at android.os.Handler.dispatchMessage(Handler.java:95) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiMessenger.dispatchMessage(TiMessenger.java:318) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiMessenger.dispatchPendingMessages(TiMessenger.java:303) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiMessenger$2.getResult(TiMessenger.java:188) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiMessenger.sendBlockingMessage(TiMessenger.java:215) E/WindowManager( 2025): at org.appcelerator.kroll.common.TiMessenger.sendBlockingRuntimeMessage(TiMessenger.java:143) E/WindowManager( 2025): at org.appcelerator.kroll.KrollProxy.fireSyncEvent(KrollProxy.java:417) E/WindowManager( 2025): at org.appcelerator.titanium.TiBaseActivity.finish(TiBaseActivity.java:831) E/WindowManager( 2025): at android.app.Activity.onBackPressed(Activity.java:1920) E/WindowManager( 2025): at android.app.Activity.onKeyUp(Activity.java:1898) E/WindowManager( 2025): at android.view.KeyEvent.dispatch(KeyEvent.java:1280) E/WindowManager( 2025): at android.app.Activity.dispatchKeyEvent(Activity.java:2078) E/WindowManager( 2025): at org.appcelerator.titanium.TiBaseActivity.dispatchKeyEvent(TiBaseActivity.java:513) E/WindowManager( 2025): at com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchKeyEvent(PhoneWindow.java:1663) E/WindowManager( 2025): at android.view.ViewRoot.deliverKeyEventToViewHierarchy(ViewRoot.java:2560) E/WindowManager( 2025): at android.view.ViewRoot.handleFinishedEvent(ViewRoot.java:2535) E/WindowManager( 2025): at android.view.ViewRoot.handleMessage(ViewRoot.java:1867) E/WindowManager( 2025): at android.os.Handler.dispatchMessage(Handler.java:99) E/WindowManager( 2025): at android.os.Looper.loop(Looper.java:130) E/WindowManager( 2025): at android.app.ActivityThread.main(ActivityThread.java:3683) E/WindowManager( 2025): at java.lang.reflect.Method.invokeNative(Native Method) E/WindowManager( 2025): at java.lang.reflect.Method.invoke(Method.java:507) E/WindowManager( 2025): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839) E/WindowManager( 2025): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597) E/WindowManager( 2025): at dalvik.system.NativeStart.main(Native Method) {code} Steps to reproduce: 1) Install KS from sample pane in Studio 1.0.8 2) Navigate to Platform > Platform Data 3) Press "back" Result: Runtime error and leaked window Expected: No runtime error, no leaked windows

    Appcelerator JIRA | 5 years ago | Eric Merriman
    android.view.WindowLeaked: Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@409094d0 that was originally added here
  3. 0

    Can't be used in landscape format

    GitHub | 2 years ago | zafyraminx
    android.view.WindowLeaked: Activity com.choiboi.imagecroppingexample.CropActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@40532fc8 that was originally added here
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Json object integrate with android

    Stack Overflow | 4 years ago
    android.view.WindowLeaked: Activity com.example.androidhive.AllProductsActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@405375e0 that was originally added here
  6. 0

    android parsing json, delete and insert values into database

    Stack Overflow | 2 years ago
    android.view.WindowLeaked: Activity www.mandiritunasfinancemobile.co.id.a1s2d3f4g5h6j7k8l9.p0.comcom.MainActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@4050a8e8 that was originally added here
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. android.view.WindowLeaked

    Activity org.appcelerator.titanium.TiActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@409094d0 that was originally added here

    at android.view.ViewRoot.<init>()
  2. Android Platform
    Dialog.show
    1. android.view.ViewRoot.<init>(ViewRoot.java:258)
    2. android.view.WindowManagerImpl.addView(WindowManagerImpl.java:148)
    3. android.view.WindowManagerImpl.addView(WindowManagerImpl.java:91)
    4. android.view.Window$LocalWindowManager.addView(Window.java:424)
    5. android.app.Dialog.show(Dialog.java:241)
    5 frames
  3. org.appcelerator.kroll
    TiJSErrorDialog$1.onCurrentActivityReady
    1. org.appcelerator.kroll.common.TiJSErrorDialog.createDialog(TiJSErrorDialog.java:204)
    2. org.appcelerator.kroll.common.TiJSErrorDialog$1.onCurrentActivityReady(TiJSErrorDialog.java:104)
    2 frames
  4. org.appcelerator.titanium
    TiApplication.waitForCurrentActivity
    1. org.appcelerator.titanium.util.TiUIHelper.waitForCurrentActivity(TiUIHelper.java:154)
    2. org.appcelerator.titanium.TiApplication.waitForCurrentActivity(TiApplication.java:702)
    2 frames
  5. org.appcelerator.kroll
    TiJSErrorDialog.handleMessage
    1. org.appcelerator.kroll.common.TiJSErrorDialog.handleOpenErrorDialog(TiJSErrorDialog.java:99)
    2. org.appcelerator.kroll.common.TiJSErrorDialog.handleMessage(TiJSErrorDialog.java:226)
    2 frames
  6. Android Platform
    Handler.dispatchMessage
    1. android.os.Handler.dispatchMessage(Handler.java:95)
    1 frame
  7. org.appcelerator.kroll
    KrollProxy.fireSyncEvent
    1. org.appcelerator.kroll.common.TiMessenger.dispatchMessage(TiMessenger.java:318)
    2. org.appcelerator.kroll.common.TiMessenger.dispatchPendingMessages(TiMessenger.java:303)
    3. org.appcelerator.kroll.common.TiMessenger$2.getResult(TiMessenger.java:188)
    4. org.appcelerator.kroll.common.TiMessenger.sendBlockingMessage(TiMessenger.java:215)
    5. org.appcelerator.kroll.common.TiMessenger.sendBlockingRuntimeMessage(TiMessenger.java:143)
    6. org.appcelerator.kroll.KrollProxy.fireSyncEvent(KrollProxy.java:417)
    6 frames
  8. org.appcelerator.titanium
    TiBaseActivity.finish
    1. org.appcelerator.titanium.TiBaseActivity.finish(TiBaseActivity.java:831)
    1 frame
  9. Android Platform
    Activity.dispatchKeyEvent
    1. android.app.Activity.onBackPressed(Activity.java:1920)
    2. android.app.Activity.onKeyUp(Activity.java:1898)
    3. android.view.KeyEvent.dispatch(KeyEvent.java:1280)
    4. android.app.Activity.dispatchKeyEvent(Activity.java:2078)
    4 frames
  10. org.appcelerator.titanium
    TiBaseActivity.dispatchKeyEvent
    1. org.appcelerator.titanium.TiBaseActivity.dispatchKeyEvent(TiBaseActivity.java:513)
    1 frame
  11. Android
    PhoneWindow$DecorView.dispatchKeyEvent
    1. com.android.internal.policy.impl.PhoneWindow$DecorView.dispatchKeyEvent(PhoneWindow.java:1663)
    1 frame
  12. Android Platform
    ActivityThread.main
    1. android.view.ViewRoot.deliverKeyEventToViewHierarchy(ViewRoot.java:2560)
    2. android.view.ViewRoot.handleFinishedEvent(ViewRoot.java:2535)
    3. android.view.ViewRoot.handleMessage(ViewRoot.java:1867)
    4. android.os.Handler.dispatchMessage(Handler.java:99)
    5. android.os.Looper.loop(Looper.java:130)
    6. android.app.ActivityThread.main(ActivityThread.java:3683)
    6 frames
  13. Java RT
    Method.invoke
    1. java.lang.reflect.Method.invokeNative(Native Method)
    2. java.lang.reflect.Method.invoke(Method.java:507)
    2 frames
  14. Android
    ZygoteInit.main
    1. com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
    2. com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
    2 frames
  15. Android Platform
    NativeStart.main
    1. dalvik.system.NativeStart.main(Native Method)
    1 frame