Philipp Lackner

Native Android YouTuber with 65k+ subscribers

Talk Title

5 Common Traps You Can Step Into When Using Coroutines






11:30 > 20 min


on Twitter

1. Talk description
Coroutines are a brilliant way to apply async programming in Kotlin projects, since they help us to avoid callback hell. On the surface, they seem to be very easy to use, however there are many not so obvious traps, you can step into if you're new to them. This presentation will cover 5 of the most common and biggest mistakes you can make when using coroutines.

2. Key takeaways

1. Using async to avoid executing suspending calls sequentially

2. Coroutines aren't cancellable by default - you have to set them up for that

3. Build your suspend functions around the concept of main-safety

4. Catching general exceptions in coroutines can mess up that cancellation is properly propagated

5. Exposing suspend functions in a ViewModel to the UI is not what you should do - the lifecycle will get in your way

3. My experience level with this topic
I've been using Kotlin for 3 years on a day-to-day basis. In that time, I've mostly used coroutines and Flows for async programming which helped me to understand the subject well, since I've had a lot of time to make mistakes and learn from them.

4. Have I given this talk before?
Not as a talk, but as a YouTube video which was extremely well received:

Having made this video, I can also benefit a lot from the feedback I got there to make the talk even better.

5. Some additional keywords
coroutines, async programming

Speaker Bio

It all started when Philipp was 13 and his mom gave him a book about C++. He immediately fell in love with coding. Over the years he got to try many awesome fields like Desktop development, game dev and backend development.
However, he found what he really enjoyed when he started with native Android development in 2019. The fact that you could build something out of nothing you always have in your pocket just felt amazing for him.
To also help others on his journey, Philipp started to share Android content on Instagram. That content was well received and his page started gaining momentum. More and more people wanted him to start a YouTube channel as well, which he also did 2 months after starting posting on Instagram.
Today, with roughly 6,000,000 views on YouTube (, Philipp is one of the biggest active native Android YouTubers and is helping the Android community with regular easy-to-understand videos. On his Instagram pages @pl.coding ( and @_philipplackner_ (,) he built a combined following of around 100,000 mobile developers from around the globe.