RenderHeads / UnityPlugin-AVProVideo

AVPro Video is a multi-platform Unity plugin for advanced video playback
https://www.renderheads.com/products/avpro-video/
224 stars 27 forks source link

Can't build with Firebase #1928

Open alpermisirli opened 4 days ago

alpermisirli commented 4 days ago

I have Firebase on my project and when I add AVPro it can't build, I've tried previously mentioned ways such as

I am using the latest release of AVPro (3.0.5) and my Unity Version is 2022.3.22f1. I am working on an M1 max machine. Trying to build on Android.

I am sharing my console log below after build is failed.

If I remove AVPro from my project my build works perfectly fine.

CommandInvokationFailure: Gradle build failed. 
/Applications/Unity/Hub/Editor/2022.3.22f1/PlaybackEngines/AndroidPlayer/OpenJDK/bin/java -classpath "/Applications/Unity/Hub/Editor/2022.3.22f1/PlaybackEngines/AndroidPlayer/Tools/gradle/lib/gradle-launcher-7.2.jar" org.gradle.launcher.GradleMain "-Dorg.gradle.jvmargs=-Xmx4096m" "assembleRelease"

Environment Variables:
AMPLITUDE_API_KEY_REDBUCKET_DEV = 46b8b46515e7632fc42a504b72e05fd0
DEBUG_ENV_VAR = UnityHub
XPC_FLAGS = 0x0
__CFBundleIdentifier = com.unity3d.unityhub
AMPLITUDE_API_KEY_GREENBUCKET_DEV = 3ded2a762163603391a425f688f990c8
AMPLITUDE_TOKEN_REDBUCKET_DEV = U4PSN7S7PuYVRODivvdcFwbu8R6IHGqa
COMMAND_MODE = unix2003
AMPLITUDE_API_KEY_GREENBUCKET_PROD = c86fea37a9e1d3f0878b96e15b111c7c
JAVA_TOOL_OPTIONS = -Dfile.encoding=UTF-8
SENTRY_ACCESS_TOKEN = 3df78d9e53f8456aa90fbae044ce1a6261421ab1d0014674bc2e933477289017
JAVA_HOME = /Applications/Unity/Hub/Editor/2022.3.22f1/PlaybackEngines/AndroidPlayer/OpenJDK
AMPLITUDE_DEPLOYMENT_KEY_RED_BUCKET_DEV = client-wbjHYrmeSR87GmWOE7LDpf7sUySOIKHm
AMPLITUDE_TOKEN_GREENBUCKET_PROD = ZpUcbAdZXJYzNSoHsAWtL_s_JppwWid9
AMPLITUDE_API_KEY = 28f3cae0b33b8b3702120c9ed1a935aa
XPC_SERVICE_NAME = application.com.unity3d.unityhub.13531170.13531176
ANDROID_NDK_ROOT = /Applications/Unity/Hub/Editor/2022.3.22f1/PlaybackEngines/AndroidPlayer/NDK
AMPLITUDE_API_KEY_STAGING = 83ee04fccc67e4fcc7dd527c4c6f1e21
WOOTRIC_CLIENT_TOKEN = NPS-aa8be4c3
USER = alper
MallocNanoZone = 0
LOGNAME = alper
__CF_USER_TEXT_ENCODING = 0x1F5:0x23:0x18
AMPLITUDE_API_KEY_YELLOWBUCKET_DEV = 48835b4d1f5e342aefe5f016324d296a
PATH = /usr/bin:/bin:/usr/sbin:/sbin
SSH_AUTH_SOCK = /private/tmp/com.apple.launchd.hAOEpoqCVs/Listeners
AMPLITUDE_API_KEY_YELLOWBUCKET_PROD = e03a9bbe92dc38a88cdb068d24c65b46
AMPLITUDE_TOKEN_REDBUCKET_PROD = jTIgKs5KTZOjiqEEVdZFbgo_VRhABduL
AMPLITUDE_TOKEN_YELLOWBUCKET_PROD = UYDQtPOw83dIfVy3SrW5oMyo7ru4PRkV
HOME = /Users/alper
TMPDIR = /var/folders/ss/9xn4452d4dlckn0lb50kg7400000gn/T/
ORIGINAL_XDG_CURRENT_DESKTOP = undefined
AMPLITUDE_TOKEN_GREENBUCKET_DEV = 84H2gMm_FJzhr3mBaX1lM1JVukmCM7d9
AMPLITUDE_TOKEN_YELLOWBUCKET_DEV = wKi8foVigDditGFvmZewRFWsEbX9Y0YO
SHELL = /bin/zsh
AMPLITUDE_API_KEY_REDBUCKET_PROD = ca12bb461ea96f9bdf5df4ded7d52994
AMPLITUDE_DEPLOYMENT_KEY_RED_BUCKET_PROD = client-zH8Y7OK1i331EKuG77C6UxN8ygcM6LzS
BURST_ANDROID_MIN_API_LEVEL = 22

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

FAILURE: Build failed with an exception.

* Where:
Build file '/Users/alper/Documents/GitHub/futureastronaut/FutureAstronaut/Library/Bee/Android/Prj/IL2CPP/Gradle/unityLibrary/build.gradle' line: 59

* What went wrong:
A problem occurred evaluating project ':unityLibrary'.
> No signature of method: build_23twilk4mnjfpbbcgktdc4nnb.android() is applicable for argument types: (build_23twilk4mnjfpbbcgktdc4nnb$_run_closure3) values: [build_23twilk4mnjfpbbcgktdc4nnb$_run_closure3@609b0ce]

* 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 https://help.gradle.org

BU??LD FAILED in 1s
]
stdout[

]
exit code: 1
UnityEditor.Android.Command.WaitForProgramToRun (UnityEditor.Utils.Program p, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at <1a9338a70cd64c718bc2b14b3805c8e8>:0)
UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at <1a9338a70cd64c718bc2b14b3805c8e8>:0)
UnityEditor.Android.Command.Run (System.String command, System.String args, System.String workingdir, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at <1a9338a70cd64c718bc2b14b3805c8e8>:0)
UnityEditor.Android.AndroidJavaTools.RunJava (System.String args, System.String workingdir, System.Action`1[T] progress, System.String error) (at <1a9338a70cd64c718bc2b14b3805c8e8>:0)
UnityEditor.Android.GradleWrapper.Run (UnityEditor.Android.AndroidJavaTools javaTools, Unity.Android.Gradle.AndroidGradle androidGradle, System.String workingdir, System.String task, System.Action`1[T] progress) (at <1a9338a70cd64c718bc2b14b3805c8e8>:0)
Rethrow as GradleInvokationException: Gradle build failed
UnityEditor.Android.GradleWrapper.Run (UnityEditor.Android.AndroidJavaTools javaTools, Unity.Android.Gradle.AndroidGradle androidGradle, System.String workingdir, System.String task, System.Action`1[T] progress) (at <1a9338a70cd64c718bc2b14b3805c8e8>:0)
UnityEditor.Android.PostProcessor.Tasks.BuildGradleProject.Execute (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at <1a9338a70cd64c718bc2b14b3805c8e8>:0)
UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at <1a9338a70cd64c718bc2b14b3805c8e8>:0)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&) (at /Users/bokken/build/output/unity/unity/Modules/IMGUI/GUIUtility.cs:203)
Chris-RH commented 4 days ago

The gradle things that you mention regarding guava, it is not an AVPro-specific issue. Its nothing that we can change as that dependency comes from media3 (Exoplayer). Its to do with different guava libraries conflicting. There are a few different solutions online, that seem to work for some people, but not others.

However I'm not seeing any guava specific errors in the log that you have posted, so are you sure that is the issue?

  1. What have Firebase said about the issue?
  2. Can you open a new project and build a project with just AVPro Video?
  3. If yes, can you add firebase to that project and try building again.
PopovYuriy commented 4 days ago

We have the same issue. It happened after updating to v3

Chris-RH commented 4 days ago

@PopovYuriy,

So are you saying that it worked with AVPro Video version 2, and the only difference is that you have updated to version 3?

PopovYuriy commented 4 days ago

@Chris-RH Yes! However, the empty project with AVPro build successfully

Chris-RH commented 4 days ago

@PopovYuriy

  1. Which version of Unity are you using?
  2. Which version of AVPro are you using?
  3. What error message are you getting?
  4. What have you tried doing to fix it?
  5. What advice have you had from Firebase?
PopovYuriy commented 3 days ago
  1. 2022.3.28
  2. v3.0.5
  3. The same errors. But also I have a warning message:

WARNING:We recommend using a newer Android Gradle plugin to use compileSdk = 34

This Android Gradle plugin (7.1.2) was tested up to compileSdk = 32

This warning can be suppressed by adding android.suppressUnsupportedCompileSdk=34 to this project's gradle.properties

  1. Currently no idea.
  2. I didn't write to Firebase, because this issue appeared after updating AVPro.