react-native-gesture-handler: undefined method `install_dependencies' for Pod:Module
Description
When i am using pod install command getting below error:
[!] Invalid `Podfile` file:
[!] Invalid `RNGestureHandler.podspec` file: undefined method `install_dependencies' for Pod:Module
Did you mean? instance_exec.
# from /Users/XXXX/Documents/MyApps/OK_RN/node_modules/react-native-gesture-handler/RNGestureHandler.podspec:48
# -------------------------------------------
# else
> install_dependencies(s, new_arch_enabled)
# end
# -------------------------------------------
Steps to reproduce
- npm i
- cd ios
- arch -x86_64 pod install
Snack or a link to a repository
xx
Gesture Handler version
2.9.0
React Native version
0.68.2
Platforms
iOS
JavaScript runtime
None
Workflow
None
Architecture
None
Build type
None
Device
None
Device model
No response
Acknowledgements
Yes
About this issue
- Original URL
- State: closed
- Created 8 months ago
- Reactions: 4
- Comments: 19 (3 by maintainers)
TEMPORARY SOLUTION:
npm i && cd ios/ && pod install
package.json
"react-native-gesture-handler": "2.9.0",
Hi! If you experience this issue try to follow steps suggested by @benminor. Sometimes reinstalling node_modules helps and I wouldn’t call it “temporary solution”. Also, removing
^
from version inpackage.json
shouldn’t matter.So if you see this problem, try reinstalling
node_modules
and thencd ios && pod install
. You can also try deletingpods
before doingpod install
:cd ios
andrm -rf Pods Podfile.lock
Let me know if it helps!
Experienced the same issue today. I noticed the only difference between one of our working react-native app projects and the failing one was that the error occured when upgrading to latest
"react-native-gesture-handler": "2.13.3"
.Solution:
2.13.2
inpackage.json
npm i && ios/ && pod install
This works for me, still it should be a temporary solution,
undefined method 'install_dependencies' for Pod:Module
problem should be fixed with the latest version of react-native-gesture-handler.try using “react-native-gesture-handler”: “^1.8.0”, it works for me