CommandInvokationFailure: Gradle build failed. unity 2019.4.22

Note: Ads\Ads\Temp\gradleOut\unityLibrary\src\main\java\com\unity3d\player\ uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
[] C:\Users\HP.gradle\caches ransforms-2\files-2.1\fbc1e4faba4192a1e90fb232d4073c82\AndroidManifest.xml:5:5-51 Error:
Missing ‘package’ key attribute on element package at [] AndroidManifest.xml:5:5-51
[] C:\Users\HP.gradle\caches ransforms-2\files-2.1\fbc1e4faba4192a1e90fb232d4073c82\AndroidManifest.xml Error:
Validation failed, exiting

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ‘:launcher:processReleaseManifest’.

Manifest merger failed with multiple errors, see logs

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at

Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8

UnityEngine.GUIUtility:ProcessEvent (int,intptr)

can anyone tell the solution of this issue


Restart unity hope everything will sort out

P.s: check/re-check gradle installed with unity & restarting unity editor and visual studio worked for me