Well, we were sailing along and the changes I was making were pretty much all cosmetic or about making things easier to use and less likely to generate errors, when suddenly, one tester got a problem. My added tick button was staying ticked even after the deadline had been reset at midnight; it was no longer reminding you you need to press the button today (whatever day that is you’re reading this).
This has something to do with the way the widget works (or worked). Of course it worked on my phone and tablet and everyone else’s phone and tablet, except one – go on, guess. So far I’ve not been able to nail this and would be really grateful for suggestion.
The joys of programming android devices is like routing around in the guts of the very devil him (or her) self. So, a loverly new person came forward to try out the now sort-of-working I’m OK and it, quite spectacularly, failed to work. It was immediately obvious that it was something to do with the connection to my SQL database, but none of the ‘helpful’ error messages I’d put in was being at all helpful. I wasn’t getting any failures to connect to the internet, no complaints about permissions not being set etc. Also, I could not replicate this error on any of my devices, virtual or real, no matter how much I messed about with network settings.
So, all I was left with was to weave a web of debugging messages into the app so that the user with these problems would be able to tell me a bit more about where the app was stopping and possibly why.
Then I thought about Android versions – maybe this user had a really old version and that was the problem so I started to investigate that. And, you know what, the problem turned out to be exactly the opposite, it was that they had Android 9. I’d been working on the dumb assumption that, as I made my app work on Lollipop as the minimum version of Android, it would work on later versions as everything I was doing was very simple stuff. This is not the case. When I set up an emulator with Android Pie (9) I immediately got all the errors my user did.
I’ll not go through the tale of the days of searching and crying that lead me to the answer, which consisted of adding one line of code to the manifest, but at bottom, Android 9 changed the default setting of something called Cleartext (me neither) which deals (somehow) with the encryption of the communication between the app and web pages via HTTP; instead of it being assumed I’d not want encryption, it now assumed I would.
For fellow coders who happen upon this post in their own search, the solution is here.
It’s always scary releasing work into the wild, even if it’s only to a couple of very supportive friends. There have already been several major re-writes of code to make everything much harder to break, I’m re-jigging the text sizes on both the app and the web pages and I’m trying to make the sign-up e-mails more friendly.
If you want to give it a go, please contact me; I’m keen to get it out there.
It’s been a real struggle but I have started what’s called an internal test on google play. This means that if I have your gmail address (i.e. google id – what you have if you use Android) I can send you a link that will let you download and install ‘Don’t Worry: I’m OK’. I changed the name because there was already a package called I’m OK and I’ve now discovered there’s one called Don’t Worry – I’m OK so I’m going to have to put some thought into the app title.
But, I’m now working on an up-date based on the feedback Google’s automated tester gave me and that should be through soon. If you want to be involved in testing, please contact me via the contacts page here giving me an e-mail address and I’ll add you to the test and send you installation details; it’s pretty much the same as installing any app from Google Play.
I’ve now added this to the options screen. It sets a flag on the database so that it doesn’t send any e-mails and it sets the widget button to grey as a reminder that the system is disabled. Currently it doesn’t inform contacts and I’m reluctant to include that feature as it’s just more e-mails going out.
… which I wasn’t but anyway. Here’s an interesting speech about using tech from Jeremy Wright. It covers a lot of ground and shows some of the government’s thinking, but it’s very much about big companies with big, complicated systems.
Jeremy Wright’s speech at Doteveryone’s Responsible Tech conference
Having looked around for ages for something that does what I’m OK does, I have found something quite close called Snug Safety. It is much more complicated than I’m OK, and it’s only available for iPhones at the moment, but it makes an interesting read.
It does a tonne of stuff which I’m OK isn’t ever going to do (I’m OK will NEVER send inspirational quotes!) , mostly because it’s trying to sell you a subscription package to an emergency response line. That’s not a bad thing, it’s just not what I’m doing here. It also has, in my opinion, a different system for letting it know you are OK, where you must press the button at a specific time of day. The advantage of that is that it can raise the alarm sooner, but I imagine it would lead to a lot of false alarms on the free version; on the paid version someone would make attempts to contact you before raising the alarm.
I know I said no more features, but…
There are a couple of interesting features that I’m considering having seen them on Snug Safety. First is an ‘I’m on holiday’ button. This would let users suspend the account for as long as they liked so they wouldn’t have to think about it while on holiday or whatever. I’m going to add this to the account management page because I think it’s actually very useful.
The second is a sort of ‘send my messages now’ button. I’m not so sure about this. It makes I’m OK a sort of panic button that actually still relies on people looking at their e-mail to respond. I suppose I think that, if someone can open I’m OK, press the panic button and them confirm it (there would need to be an ‘Are You Sure’ button too), they could make a phone call or send a text. But, if I get around to having I’m OK send texts, then this might be worth revisiting.