I tested your invalid license case and managed to reproduce it. I have made some server side changes and can no longer reproduce the invalid license state. Can you see if it’s better for you now also?
They list the events that are returned relating to the license callback.
Yes, there should be no problem with that.
So far I didn’t see invalid license again.
Now I call my chartboost init again like this:
if (event.name == "license") then if (event.status == "invalid" or event.status == "networkError") then \_myChartboostInit() end end
And I also call my chartboost init when application resume if Chartboost flag is not set as ready.
If you see anything inappropriate, please let me know. I have submitted it to App Store and have my fingers crossed. I like my last result with Chartboost, the revenue is higher than I expected, but I only tested a few days before I found the startup problem for some users. Hopefully this version will fix it. I will let you know.
I just find it weird how people have been using the plugin for months with no issues reported like this. And those users have hundreds of thousands of daily players. By this, i’m not trying to deny that it happens, just saying I wonder if there is a function call chain that is perhaps unique to the way most people are using perhaps, where it fails under a certain order of execution perhaps?
But if you can’t reproduce it locally, then that throws that theory out the window too i guess.
Is this only on Android or iOS also? Your waiting for the license callback to give you a valid response before calling any chartboost methods like you said before right?
The worst thing is that neither of us can reproduce it…
All the reports about my app getting stuck are from iOS.
Earlier, I call init() right after the app starts and they said they couldn’t start the app. And for this new version, I call init() with a 2-second delay after the app starts, now the users said my app starts and gets stuck after a few seconds. I think it’s not just coincidence.
Of course now I only call any chartboost.* function after init returns valid license. I have a flag to be checked before every chartboost function(). If it’s not true, no chartboost function will be called.
Do you think “caching” could ever cause this? I mean I call cache function right after init() returns valid license in the callback.
It’s very hard to reproduce. There are only a few users complaining about this comparing to my user base. I still see Chartboost revenue coming in everyday, I don’t want to remove Chartboost either. But my app is a reader app, not a small game, I can’t afford to lose reader’s loyalty to using my app. So I am very sensitive about user reports (and give them the reporting channel right in my app). I think they see this problem randomly too, not every time, or they can’t report this problem inside my app.
The Android crash only happened in rare occasion. Does it also happen in iOS? Would the problem above be associated with this crash?
I will take a look at the iOS version and see if the same race condition is possible there.
Don’t worry, we will get to the bottom of this. At least the android log gave us something to go on. I know this situation isn’t ideal and can appreciate your situation, as you know it’s just that much harder as we can’t reproduce it.
It’s happening every time for me (app crashes). Before I updated to the latest version it worked fine (aside from the ridiculousness of synchronous license call). Definitely test thoroughly if you’re building using this latest version now.
Quick question if I may, how do you update to the “latest version”? I thought it was a plugin that was always up to date? I print out the version of the plugin and it says 1.3 Maybe I am just confuse on how plugins works. I too have an app waiting for review using the plugin.
Whenever you actually compile it uses whatever the current version is at that time. The version that’s crashing for me is one I compiled today. The newest version came out like a day ago from what I can see so I’m assuming this issue started occurring after that. I’m trying to figure out if anyone else is experiencing this.
I was advised by Gremlin that don’t call any chartboost function if the license is not validated yet, so I added a flag in the chartboost callback:
if (event.name == "license" and event.status == "valid") then \_isChartboostReady = true end
I check this flag before I call any chartboost.* function. This will avoid the crash.
Hence, I think you (dfoxinator) should have the same problem that you don’t get any callback from Chartboost plugin. Please take a look if you get any callback from Chartboost plugin after init() ?
Now the problem is why there is no callback from chartboost.init() after all?
PS. the weird thing is that I built again with another app, and that app is ok. It’s very confusing now. I have tried several times and confirmed all keys are correct (they were both using Chartboost plugin without problem at the first place), and what I am seeing now is that one app works and the other app has no callback after init() no matter what. There is a log “Invalid Parameter: URL argument was malformed URL” right after I call the init(), I am not sure if this is generated by my own app or Chartboost plugin if this might give some clue?
Hmm, good investigation. I didn’t have a chance to do any debugging because I had to re-submit my game right away with a different ad provider. However, what you found seems like the probable issue. I do not check to see if the licensing call succeeded in my other chartboost calls so it would make sense that if that call was broken nothing else would work.
That’s very weird that one of your apps works and the other doesn’t. Not sure what’s going on accept it’s clear that there’s a problem with the plugin
It’s not just about the crash… the problem is that I don’t receive callback after init(). I cannot use Chartboost for one of my apps after building with latest version of the plugin.
UPDATE: Both of the reported issues have been fixed
The fixed version of both of these issues is v1.4.1 - the fixed plugins have been pushed to Corona and should be available within ~1.5 hours from the time of this post.
You can check the plugin version via: chartboost.getPluginVersion()
Ok, if that is due to unstable network status for the client side, it’s always possible.
It’s also a pity that if a client device starts up without a stable connection, chartboost will lose the opportunity to be initiated. Or do you recommend to init again during application suspend/resume?