Based on the above, probably the most stable config is to use Gradle 8.1.1 (along with OpenJDK 17).
We can configure it for 8.2.1 and thus open a LAMW project in Android Studio "Hedgehog" without complaints...
that is: JDK 17 + Gradle 8.2.1 + Android SDK "platform-34" !