react-native-vision-camera icon indicating copy to clipboard operation
react-native-vision-camera copied to clipboard

πŸ› react-native 0.69.3 android build crash

Open BartoszDombrow opened this issue 2 years ago β€’ 10 comments

What were you trying to do?

I want to build an android application, but I got this error I am working on RN 0.69.3

Reproduceable Code

FAILURE: Build failed with an exception.

* Where:
Build file 'C:\Users\48791\OneDrive\Pulpit\sewio-mobile\node_modules\react-native-vision-camera\android\build.gradle' line: 231

* What went wrong:
A problem occurred evaluating project ':react-native-vision-camera'.
> Expected directory 'C:\Users\48791\OneDrive\Pulpit\sewio-mobile\node_modules/react-native/android' to contain exactly one file, however, it contains more than one file.

What happened instead?

App can not build and npx react-native run-android crash. If i disable frame processors in android/gradle.propeties app builds correctly.

Relevant log output

No response

Device

Samsung S8

VisionCamera Version

2.14.0

Additional information

BartoszDombrow avatar Jul 26 '22 10:07 BartoszDombrow

Same issue on

React Native - 0.69.1 React Native Vision Camera - 2.14.0 React Native Reanimated - 2.9.1 Vision Camera Code Scanner - 2.14.1

JulianErnest avatar Jul 28 '22 07:07 JulianErnest

same issue

thangovn avatar Jul 28 '22 09:07 thangovn

Build was successful after running npx patch-package react-native-vision-camera Must have the patch installed though, see nobane's answer above. Weird cause I was running the 2.14.0 one which should've had the fix.

JulianErnest avatar Jul 29 '22 06:07 JulianErnest

Same issue for me: "react": "18.0.0", "react-native": "0.69.3", "react-native-reanimated": "^2.9.1", "react-native-vision-camera": "^2.14.0"

I ran the npx patch call and nothing changed

Edit to say that I got it to work using a workaround. I applied patch 2.13.5 to my project and now it builds and installs on my android phone. The dependencies now look like this:

"patch-package": "^6.4.7",
"react": "18.0.0",
"react-native": "0.69.3",
"react-native-reanimated": "^2.9.1",
"react-native-vision-camera": "^2.13.5"

gtzippy avatar Jul 29 '22 13:07 gtzippy

should really think about merging this one https://github.com/mrousavy/react-native-vision-camera/pull/1116/files

jbrodriguez avatar Jul 29 '22 21:07 jbrodriguez

add disableFrameProcessors=true in gradle.properties will work on android

thangovn avatar Jul 30 '22 04:07 thangovn

That fixes the build issue, but since we are still using frame processors, we can't turn that flag off.

spsaucier avatar Aug 01 '22 20:08 spsaucier

@spsaucier did you find anything on this? I'm stuck with the same issue, also need to keep frame processors on.

onesmartguy avatar Aug 01 '22 22:08 onesmartguy

I haven’t - hoping the relevant PR will be merged very soon ( https://github.com/mrousavy/react-native-vision-camera/pull/1116).

On Mon, Aug 1, 2022 at 6:43 PM Eddie Flores @.***> wrote:

@spsaucier https://github.com/spsaucier did you find anything on this? I'm stuck with the same issue, also need to keep frame processors on.

β€” Reply to this email directly, view it on GitHub https://github.com/mrousavy/react-native-vision-camera/issues/1164#issuecomment-1201805680, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAERRL7E4LLYZ37B5YTRTJTVXBHH3ANCNFSM54VMGWZA . You are receiving this because you were mentioned.Message ID: @.***>

--


Stephen Saucier (706) 225-9155

spsaucier avatar Aug 01 '22 23:08 spsaucier

This should be fixed as of the latest release, #1116 was superseded by #1186 and merged in the latest release

TiKevin83 avatar Aug 30 '22 15:08 TiKevin83