react-native: Failed to install CocoaPods dependencies when creating a new project

Description

✔ Downloading template ✔ Copying template ✔ Processing template ✖ Installing CocoaPods dependencies (this may take a few minutes) ✖ Installing CocoaPods dependencies (this may take a few minutes) error Error: Failed to install CocoaPods dependencies for iOS project, which is required by this template.

Version

0.71.0

Output of npx react-native info

I am using rbenv to manage ruby versions

rbenv versions system 2.7.6

Steps to reproduce

npx react-native init PandaParking --template react-native-template-typescript

Snack, code example, screenshot, or link to a repository

image

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Comments: 16 (6 by maintainers)

Most upvoted comments

Hi @mrsants. The --template react-native-template-typescript is not required anymore, as we are shipping typescript types by default. See here for more details.

We need more information to help you out, but it looks like a problem in your local setup. Could you try to install the pods manually? To do so:

cd PandaParking/ios
bundle install # you need to run this only once
bundle exec pod install

This will output a more informative error and we can continue from there.

Thank you so much for your patience.

We tried many time but we got the same error.

The error says: Connection reset by peer, errno 54 which means that your connection dropped. Try again, please.

Installing manually works fine. Thanks for your reply. 👋🏼

@betomoedano can you try to manually install the dependencies by:

  1. cd <yourProject>/ios
  2. bundle install
  3. bundle exec pod install ?

If it fails, can you report the error?