I got a similar error. I found out that I initialized the foreground service for foreground microphone access, while the microphone permission itself was not yet given.