Hello.
We released an app last summer (both ios and android) and it's been working just fine. It's a quiz-app which is mostly just a client which talks to a server etc. Nothing too interesting or unusual, again it's been working just fine.
A month ago we did some minor updates (changing a hardcoded IP-adress to a domain-name, and adding a banner in the beginning) and everything worked fine. That was until the client (it was an ordered job) started to complain that the "couldnt log in" anymore.
I downloaded the app myself and yes, it froze on the login-screen and crashed after a while.
I launch titanium and build the app again (last build was 18th mars and it worked just fine on my phone back then) and I seem to have the same problem....
The log keeps pumping out "not enough memory"-messages and after a while it crashes.
This seems weird since first of all we do have a lot of views but they don't contain much. I tried disabling loading profile images of the player and his/her friends etc, but still the same thing.
I managed to half go-around the problem by hiding views that are not in use and adding them only when the user needs to see them etc, but it has little effect. If the user keeps going back and forth between for example the welcome-screen and the highscore-list the app WILL crash eventually.
My test-device is a Sony Xperia Z3 which should have way enough memory to run this app. I also tested on Samsung Galaxy S4 and it behave the same way.
The thing is, since the app RAN JUST FINE before I find it hard that the "running out of memory"-problem is actually about the app running out of memory. Something has changed.
I then started to download the latest Android SDKs but I can not get the app to run with anything higher than "19".
21 just keeps crashing after about 4-5 seconds after the app started, I've commented out everything to find out where it crashes but it doesn't seem to matter. I can go into the mainview and then do nothing more and 4-5 seconds later it says "unfornately THE APP has crashed blabla".
One interesting thing with this is that the app actually DO continue to work in the background for a while after the "unfornately"-message has been popped.
With SDK 22 I can't even build, I get a "<declare-stylable android:preserveIconSpacing was not found" or similar. I've googled this error message and found like 2-3 articles that didn't help me solve my problem (both unrelated to Titanium Appcelerator). Am I really the only one who gets this error message or is SDK 22 simply not supported by Titanium? Anyway ....
I'm in kind of deep trouble here since the client wants the app out asap and I feel like a complete fool not kknowing what's wrong... any help will be deeply appreciated.
I'm using Ti SDK 3.5.1 GA, but I also tried lower versions with the same result.
Here's an example of one of the many memory-related error-messages I get: art: Clamp target GC heap from 205MB to 192MB [INFO] : art: Alloc concurrent mark sweep GC freed 4(128B) AllocSpace objects, 0(0B) LOS objects, 1% free, 189MB/192MB, paused 662us total 28.508ms [ERROR] : art: Throwing OutOfMemoryError "Failed to allocate a 6046092 byte allocation with 2138260 free bytes and 2MB until OOM"
And here's the exact message what happens when I try to build with SDK 22:
"ERROR: In <declare-styleable> MenuView, unable to find attribute android:preserveIconSpacing"
Best Regards: Albin - A super-frustrated TI-developer.