“Spotted a Bug on Your Smart TV? Send It to Us!” Says Tomáš Zeman, Team Leader of the Showmax Smart TV and Web Team
At our Prague Sky | Showmax engineering office, we have a place where you feel like you are in a newsroom – you’re surrounded by the tens of televisions which our developers work on when testing the smart tv app. For three years, Tomáš Zeman has been leading the Showmax smart tv team. He kept everything working even after the Covid outbreak when we all worked from home and his team had to test the app on TVs remotely. Tomáš was among the first people who recently transitioned to the Sky teams, making this the perfect moment to speak about what makes his work special.
Your office corner is full of various televisions. How many have you had there? Are you counting the total number?
I stopped counting a while ago. But I guess we have around 25 or 30 TVs there currently and that’s the maximum we’ve had so far. We also have more models, which our customers don’t use that much, in storage, because we don’t have space to hang them all on the walls.
As the time goes, it’s much harder to hang the same number of models on the wall, the screens grow in size. Back in 2017, we were able to find TVs with 32” screen easily, now it’s almost impossible – the cheapest models are usually over 40”, and such large screens fill up our precious space pretty quickly.
Why isn't it sufficient to have, for example, 5 pieces? Do they vary so much from each other?
Unfortunately, yes. Every year new models appear and usually come with new operating systems which bring us new challenges and bugs.
But it doesn’t stop there. Even models released within a single year can behave differently. One firmware could be completely broken (memory leaks, bad garbage collections, etc.) whereas another one works just fine.
The world of TVs is different from what we know on mobile phones or computers. Keeping the software in shape is harder. Not all vendors provide regular updates, major OS updates are even less likely. On top of that, users themselves are less used to updating their TVs – even if they are lucky enough to get an update to install they can ignore it.
Your team was the only one responsible for web and Smart TV apps at Showmax. Have you established a cooperation with any devs or testing team in Africa?
Actually, we have been in contact with (DStv*) front-end developers in Africa for years. They had a similar roadmap and usually faced similar issues while implementing new features like live streaming, 4K support and such. So, we often shared the knowledge.
Getting back to testing, are all the TVs available and common in Africa also available here?
I think it varies from brand to brand. Some vendors sell very similar TVs in both markets but there are others who, in Africa, sell very different models, different mainly in the behavior.
In the past, our African customers or colleagues shipped us several models – those we had major issues with – so that we could test the app on them. It’s not easy to get the stuff to Europe but sometimes it's the only way.
What do you do with TVs you no longer need?
I think each TV we have ever had still has value to us. Obviously, our TV lab in the office is not infinite so we sometimes have to take some TVs off the wall to make space for new ones. But we keep them in our storage and don’t have any plans to get rid of them as long as they are still officially supported. Old TVs are a treasure you can’t buy again and we never know what weird model-specific bug lurks behind a corner.
How long have you been leading the Showmax web and Smart TV team?
It’s been three years already.
What has changed during those years in terms of technology and your approach to development of the app?
The world of Smart TV doesn’t evolve that quickly so we were not forced to completely rewrite our application using new technologies or change our approaches.
Was there a truly challenging moment, a real debugging nightmare?
Certainly! There were many moments. The world of Smart TVs is full of landmines 🙂
Give us a story then.
I will mention maybe the two weirdest ones.
We had customers on specific LG models often complaining about their apps randomly crashing. Our investigation showed that those models were crashing while trying to translate labels. We were not able to exactly determine the root cause on our TVs in the office so we only mitigated the impact, caught those exceptions and just left part of the app untranslated.
But then, stranger things started happening. The app sometimes went from fully translated to partially translated state and back while you were using it.
To continue with the investigation, we had to have the TV encountering these issues shipped from Africa to us.
So, we then dug deeper and revealed a truly horrifying truth. There was a variable declared outside of a ”for loop” and used (read-only) inside of the loop. The code was really nothing special. Then when the exception happened, the variable was suddenly undefined, or with completely random value and such. It turned out that the garbage collector just collected the variable in use and the memory was allocated for something else causing it to crash.
The for loop was part of an i18n external library so in order to fix this, we had to ditch the library and write our own implementation avoiding that particular issue.
So without having the TV shipped to the Czech republic you wouldn’t have been able to solve it. Terrible! And the second story?
The second moment was related to “stuck” promises in, again, LG TVs.
We sometimes reload our app internally to make sure people have the up-to-date version. And during one of those reloads, the app stayed stuck and didn’t load. But, when you performed any user action, pressed any button on your remote, the TV loaded and everything was just fine.
It took a while to investigate this. Eventually, it turned out that the TV is another one-of-a-kind piece – one of the promises in bootchain remained pending forever due to some internal bug either in the promise implementation or in the TV SDK and the user action got it settled.
How have you fixed it?
We basically called setTimeout with zero timeout and with a no-op function. A terrible hack to unblock the stuck promises, right? But yeah, it worked.
The world of old TVs is really full of surprises…
Tomáš at the WeStream meetup #2 in April
You have recently moved to Sky teams, to work again on the web app and you are already growing the team here in Prague. What do you expect from an ideal candidate for a job in your team?
And we can teach everything else that is specific to our team and not knowing it in advance is not really an issue.
You work a lot remotely. How is it possible when you have the Smart TV wall in the office?
It wasn’t common a few years back. We used to be in the office all the time in order to be able to use our TVs for development. This changed instantly with covid pandemic when our offices were closed. We had to find a way to make our development scalable even in such conditions.
Long story short, we took a CandyBox, a surveillance camera, made a custom VPN routing to allow direct communication with the TVs and the remote development environment was ready. We had a talk about this on the Frontendisti meetup and there’s also a blog post so feel free to check it out. It really gave us the flexibility we needed and opened even more opportunities for hiring.
To learn more about the CandyBox and the solution come chat with Tomáš and Petr Češka from Suitest at the next WeStream meetup on June 29.
What is the core idea or value that pushes the team forward?
I think the core idea is that we are all responsible for what we do, it is our product, and we work on it together. We really try to help each other every day and in case of issues everybody is willing to step in and help to resolve them.
And that doesn’t only apply to our team but to everybody around. That’s the spirit we try to embrace here.
The Showmax smart tv & web team that was led by Tomáš is currently in the experienced hands of Michal Topinka. You can meet and chat with both at the upcoming WeStream meetup on June 29 in our offices in Nové Butovice.
*DStv is a sub-Saharan African video entertainment company owned by MultiChoice. It was launched in 1995 and provides multiple entertainment channels and services to customers across the continent via satellite, online and mobile apps.