R8 Shrinker Error When Building AAB in FlutterFlow - Any Solutions?

Troubleshooting

Hi FlutterFlow Community!

I'm encountering an error while trying to deploy my app to the Google Play Store. When building the AAB, I'm getting the following error:

```

FAILURE: Build failed with an exception.

Execution failed for task ':app:minifyReleaseWithR8'

> Compilation failed to complete: androidx.media3.exoplayer.dash.manifest.DashManifestParser

```

The error seems to be related to R8 code optimization with the media3-exoplayer-dash library. The full error message suggests using the --no-shrink flag, but I'm not sure how to implement this in FlutterFlow's deployment process.

Here's the complete error log:

```

BUILD FAILED in 5m 5s

Running Gradle task 'bundleRelease'...

[!] The shrinker may have failed to optimize the Java bytecode.

To disable the shrinker, pass the --no-shrink flag to this command.

```

I'm using a custom widget that implements video playback functionality. Has anyone encountered this issue before? Any suggestions on how to resolve this in the FlutterFlow environment would be greatly appreciated.

Thanks in advance for your help!

#FlutterFlowHelp #BuildError #AndroidDeployment

What have you tried so far?

- Updated video_player dependency to version ^2.8.7 in pubspec.yaml

- The error persists even after updating the package version

- This issue seems to be specifically related to the R8 optimization process rather than the video_player package version

I suspect this might be a build-time optimization issue rather than a package incompatibility issue, but I'm not sure how to resolve this in the FlutterFlow environment.

Would appreciate any guidance on how to:

1. Either disable R8 optimization in FlutterFlow's build process

2. Or properly configure R8 to handle the ExoPlayer library

Has anyone successfully deployed a Flutter app with video playback functionality through FlutterFlow?

Did you check FlutterFlow's Documentation for this topic?
Yes
3
2 replies