Android Production Build Failed after installing ffmpeg-kit-react-native

There should be more info on the failure above this in the logs.

If I run npx expo-doctor on your dependencies I get this:

% npx expo-doctor
✔ Validating global prerequisites versions
✔ Checking for incompatible packages
✔ Checking for conflicting global packages in project
✖ Verifying prebuild support package versions are compatible
Issues:
  Expected package @expo/config-plugins@~6.0.0
  Found invalid:
    @expo/config-plugins@4.1.1
    (for more info, run: npm why @expo/config-plugins)
Advice:
  • Upgrade dependencies that are using the invalid package versions.
✔ Checking dependency versions for compatibility with the installed Expo SDK
✔ Validating Expo Config
✖ Checking package.json for common issues
Issues:
  The package "expo-modules-core" should not be installed directly in your project. It is a dependency of other Expo packages and should be installed automatically.

✖ Found one or more possible issues with the project. See above logs for issues and advice to resolve.

So, first uninstall/remove the expo-modules-core dependency.

After that you should use npm why to find out what’s causing the old version of @expo/config-plugins to be installed. This is what I get when I try it with your dependencies:

% npm why "@expo/config-plugins@4.1.1"
@expo/config-plugins@4.1.1
node_modules/@expo/webpack-config/node_modules/@expo/config-plugins
  @expo/config-plugins@"4.1.1" from @expo/config@6.0.20
  node_modules/@expo/webpack-config/node_modules/@expo/config
    @expo/config@"6.0.20" from @expo/webpack-config@18.0.4
    node_modules/@expo/webpack-config
      @expo/webpack-config@"^18.0.1" from the root project

This points to @expo/webpack-config being the cause of the old version of @expo/config-plugins. Do you need it? If you need to customise the Webpack config I don’t think you need that anymore. According to Bundle with webpack - Expo Documentation you just need to run npx expo customize webpack.config.js and then make changes as per the rest of that page.

If I remove that and re-run expo doctor, it no longer complains about anything.

If you do the above does it help?

1 Like