Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-25546

Android: Simple Code Crash after installing Titanium SDK 7.0.0 Beta

    Details

      Description

      Steps to reproduce:

      1. Create a new classic app
      2. Only have this code in the app.js file
      3. Build to Android

      Ti.API.log("App Start");
      var testVar = {testObject: "testvalue"};
              
      var testData = testVar.testObject;
      Ti.API.log(testVar);
      Ti.API.log(testData);
      function testFunction(testVar){
              
              Ti.API.log("TestFunction");
              
              Ti.API.log(testVar);
              
              var newTestVar = {testObject: "testvalue"};
              var newTestData = newTestVar.testObject;
              
              Ti.API.log(newTestVar);
              Ti.API.log(newTestData);
      }
      testFunction(testVar);
      

      App will build and fail with the following log

      -- Start application log -----------------------------------------------------
      [INFO] :   TiApplication: (main) [0,0] checkpoint, app created.
      [INFO] :   TiApplication: (main) [23,23] Titanium 7.0.0 (2017/11/17 15:29 undefined)
      [INFO] :   MultiDex: VM with version 2.1.0 has multidex support
      [INFO] :   MultiDex: install
      [INFO] :   MultiDex: VM has multidex support, MultiDex support library is disabled.
      [INFO] :   DatabaseHelper: No value in database for platform key: 'unique_machine_id' returning supplied default ''
      [INFO] :   DatabaseHelper: No value in database for platform key: 'hardware_machine_id' returning supplied default ''
      [WARN] :   TiAndroid: (main) [746,769] Application instance no longer available. Unable to get current activity.
      [WARN] :   TiAndroid: (main) [1,770] Application instance no longer available. Unable to get current activity.
      [WARN] :   TiAndroid: (main) [4,774] Application instance no longer available. Unable to get current activity.
      [INFO] :   TiApplication: (main) [17,791] Titanium Javascript runtime: v8
      [WARN] :   art: Before Android 4.1, method android.graphics.PorterDuffColorFilter android.support.graphics.drawable.VectorDrawableCompat.updateTintFilter(android.graphics.PorterDuffColorFilter, android.content.res.ColorStateList, android.graphics.PorterDuff$Mode) would have incorrectly overridden the package-private method in android.graphics.drawable.Drawable
      [INFO] :   TiRootActivity: (main) [0,0] checkpoint, on root activity create, savedInstanceState: null
      [INFO] :   App Start
      

      I have been testing my app on Android and have found some very random bugs in Android, everything works perfectly on iOS.

      The funny thing is that my app has tons of code, about 250 000 lines, and most of it works, but then randomly at one location when I try to access an object data as in this example it crashes, even though I do it in many other locations, the location it fails is at most likely the highest? point in the code, the point with the most layers of callsbacks functions objects so that might be why.

      I tracked it down to object not being set and objects not being usable, as soon as I access an object data the app crashes....then I ran this test in my app in different location and finally in the alloy.js file, and it crashed there.

      As I said this fails on a Clean Classic App as well and has been confirmed by Yordan Banev.

      I am not sure if this is something caused by me installing Titanium 7.0.0 Beta, if so how can I remove that and get back to a working environment?

      I have lost 2 days tracking this down..

        Attachments

          Activity

            People

            • Assignee:
              ybanev Yordan Banev
              Reporter:
              dieskim David van de Meer
              Reviewer:
              Gary Mathews
            • Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Backbone Issue Sync

                • Titanium SDK/CLI <> Titanium Mobile
                  Synced with:
                  TIMOB-5998
                  Sync status:
                  ERROR
                  Last received:
                  Last sent:

                  Git Source Code