[SPARK-3293] yarn's web show "SUCCEEDED" when the driver throw a exception in yarn-client

Feels like with your changes there's a possibility that `finish()` might never be called. Might be better to add a call to that method here before returning.