tvOS : Silent Termination

I have an app written in Swift under tvOS. 99.9999% of the time it runs just fine… but once in a blue moon, I’ll perform some action (not always the same one), and the app just goes back to the home screen. No messages, no errors, no warnings, and so far it has been impossilbe to replicate on demand… Anyone have any ideas how I might be able to track this down? Things like NIL object errors and the like always trigger a message, and give “some” indication of about where it occurred… but this is giving me zip, zero nada

And NO log on an actual device ?
Or in the simulator ?
Thats weird

yes and no… it seems (after looking around) that there IS some kind of “console” logs, but they have to be activated before the app is executed… guess they degrade performance, which make sense seeing as it needs to commuicate that informaiton from the ATV back to the Mac that is running Xcode.

Will set that up tommorow, and then wait for it to fail again… this is only the 3rd time in the last week it has happened :frowning:

Yeah without the log its a WAG to figure out what might be doing it

Hopefully the log can tell you something

I had a thought in the middle of the night as to what might be causing it… unfortunatly that wasn’t it

I thought the creation of super long sequences of cards but not

I wonder if it’s relaunching.

Can you set a var show show on screen that only appears before x’oclock and then run the app before then.

Then play and let it sit and then see if the var value stops showing?

it is not “relaunching” as it lands on the tvOS homescreen. but I am going to put debug messages in the appdelegate functions to see if any of the “exit” protocols are being used (which they should not)

1 Like

yeah the “magic return to Home Screen” capabilities of iOS & its cousins are … uh … nifty

but the lack of logs telling you anything is troublesome

there should be something somewhere

hopefully that can be found & the problem reproduced

Yeah… if I knew that all I had to do was execute a specific sequence of events, I could have it patched up in no time, but that doesn’t seem to be the case. So for now, developement will contain as normal, and hopefully the logs etc I’ve activated will point to the culprit if/when it happens again


Well it happened again… sigh.
but it did NOT call any of the appdelegate or viewcontroller exit protocols like I’d hoped.

so I guess I need to turn on the external logs and hope it happens again (I’m sure it will)

I just wish Apple would fix the damn breakpoints in Xcode

I thought you HAD turned the logs on ?

Its entirely possible its the kind of quit/crash that ONLY the OS can see occur
And so it can log the termination but the app itself punts in a way the app delegate never gets called

no I had no turned the logs on yet… hoped that appdelegate would show me the errors of my ways :slight_smile:

I did find that it seems to occur when I “pickup” a stack of cards and drop them on another pile. BUT not all the time … so I still can’t replicate it on demand

I truly HATE those “sometimes it does …” problems
Several existed in the Xojo IDE and getting a video or something to give me a clue where to track it down was always an issue
So unfortunately they often couldn’t get solved regardless of any desire to do so