Agreed. This isn’t the end of the world, but there have been a few days where I’ve done a ride in the morning, then left the TR app open so I would remember to write some notes about my ride later in the day, only to discover that my battery is dead, probably from the power assertion preventing display sleep.
I can confirm that the power assertion is added at the start of a workout, and then not removed after the workout is ended.
To replicate, on the latest Mac app release, I did
pmset -g assertions > app_not_started.txt (No TR assertions)
- Start the TR app.
pmset -g assertions > app_started.txt (No TR assertions)
- Load up a workout: Lamarck
pmset -g assertions > workout_loaded.txt (No TR assertions)
- START the workout…
pmset -g assertions > workout_started.txt (Now there’s a power assertion for the TR process).
- ENDED the workout because I have to do that tomorrow morning and I’m already nervous enough without piling on some bonus stress!
pmset -g assertions > workout_ended.txt (The power assertion is still active).
- Quit the app.
pmset -g assertions > app_quit.txt (The power assertion is now gone).
Redirecting the output into text files was just so I could diff the output.
I would imagine it needs an
IOPMAssertionRelease after the workout ends, but that’s macOS only, and I feel like I’ve heard @Nate_Pearson say the Mac stuff is using a shared iOS / macOS (and maybe more) codebase (Xamarin?), so maybe that stuff is shelling out for Mac or something.
Anyway, thanks for a great product!