I am facing this issue after changing the Ktor version to 3.2.0.
com.android.tools.r8.internal.Qf: Space characters in SimpleName 'use streaming syntax' are not allowed prior to DEX version 040
I am using Kotlin version 2.2.0. I rechecked my whole code there is no special character inside any class name.
This is a bug in Ktor 3.2.0 which is fixed in Ktor 3.2.1. There is also a workaround available.