picker
picker copied to clipboard
Failed to build android after react native 0.72.3
After upgrading react-native: 0.72.3
, android building is failing:
FAILURE: Build failed with an exception.
* What went wrong:
Some problems were found with the configuration of task ':react-native-picker_picker:packageDebugResources' (type 'MergeResources').
- Gradle detected a problem with the following location: '/Users/Yasir/projects/keleya/de.keleya.pregnancy/node_modules/@react-native-picker/picker/android/build/generated/res/rs/debug'.
Reason: Task ':react-native-picker_picker:packageDebugResources' uses this output of task ':@react-native-picker_picker:compileDebugRenderscript' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed.
Possible solutions:
1. Declare task ':@react-native-picker_picker:compileDebugRenderscript' as an input of ':react-native-picker_picker:packageDebugResources'.
2. Declare an explicit dependency on ':@react-native-picker_picker:compileDebugRenderscript' from ':react-native-picker_picker:packageDebugResources' using Task#dependsOn.
3. Declare an explicit dependency on ':@react-native-picker_picker:compileDebugRenderscript' from ':react-native-picker_picker:packageDebugResources' using Task#mustRunAfter.
Please refer to https://docs.gradle.org/8.0.1/userguide/validation_problems.html#implicit_dependency for more details about this problem.
- Gradle detected a problem with the following location: '/Users/Yasir/projects/keleya/de.keleya.pregnancy/node_modules/@react-native-picker/picker/android/build/generated/res/resValues/debug'.
Reason: Task ':react-native-picker_picker:packageDebugResources' uses this output of task ':@react-native-picker_picker:generateDebugResValues' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed.
Possible solutions:
1. Declare task ':@react-native-picker_picker:generateDebugResValues' as an input of ':react-native-picker_picker:packageDebugResources'.
2. Declare an explicit dependency on ':@react-native-picker_picker:generateDebugResValues' from ':react-native-picker_picker:packageDebugResources' using Task#dependsOn.
3. Declare an explicit dependency on ':@react-native-picker_picker:generateDebugResValues' from ':react-native-picker_picker:packageDebugResources' using Task#mustRunAfter.
Please refer to https://docs.gradle.org/8.0.1/userguide/validation_problems.html#implicit_dependency for more details about this problem.
Enviroment
react-native: 0.72.3
@react-native-picker/picker: 2.5.1
same error
Same :(
I’m using 2.4.8 without any problems. The details for the rn upgrade 0.72.3 were important for many packages I am using. Maybe downgrade? I didn’t look at changes since and I haven’t upgraded this package yet.
@ajp8164 that version fails, doesn't support newarch.
This lib is building perfectly fine for me with newArchitecture
enabled [Android, iOS].
@roots-ai && @ys-sherzad maybe you can try updating your dependencies, but of course this might break other things 😢
My versions
"@react-native-picker/picker": "^2.6.1",
"expo": "^50.0.6",
"react-native": "0.73.3",
of course many more but i think they are not relevant.