Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to install CocoaPods dependencies when creating a new project #35852

Closed
ghost opened this issue Jan 17, 2023 · 16 comments
Closed

Failed to install CocoaPods dependencies when creating a new project #35852

ghost opened this issue Jan 17, 2023 · 16 comments
Labels
Platform: iOS iOS applications.

Comments

@ghost
Copy link

ghost commented Jan 17, 2023

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

@ghost ghost added the Needs: Triage 🔍 label Jan 17, 2023
@cipolleschi
Copy link
Contributor

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.

@migueldaipre
Copy link
Collaborator

@mrsants what version of ruby ​​are you on?

@ghost
Copy link
Author

ghost commented Jan 24, 2023

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.

i tested only with npx react-native init AwesomeProject and have the same error

Captura de Tela 2023-01-23 às 23 45 12

Details, I can install the pods with pod install and I am using rbenv to manage ruby versions:

ruby 2.7.6p219 (2022-04-12 revision c9c2245c0a) [x86_64-darwin22]

➜ xxxxxxxx git:(main) ✗ rbenv versions
system
2.7.5
2.7.6

@github-actions github-actions bot added Needs: Attention Issues where the author has responded to feedback. and removed Needs: Author Feedback labels Jan 24, 2023
@cipolleschi
Copy link
Contributor

The image posted in the last message does not present any error. It looks it is taking more time to install them.

You can confirm that you can successfully run

cd AwesomePandaParking/ios
bundle install
bundle exec pod install

And these commands does not output any error?


Another test you can do is to run

npx react-native init AwesomePandaParking --skip-install
cd AwesomePandaParking
yarn install
cd ios
bundle install
bundle exec pod install

This basically create the app without installing the dependencies, so you have to install them yourself, but at least we can try to understand what's going wrong.

Thank you for your patience!

@cortinico cortinico removed the Needs: Attention Issues where the author has responded to feedback. label Jan 24, 2023
@ghost
Copy link
Author

ghost commented Jan 25, 2023

npx react-native init AwesomePandaParking --skip-install

using skip install and installing the pods manually works fine, I don't know if there's a need to keep the issue open, but it would be interesting to investigate the other possibility

@cipolleschi
Copy link
Contributor

it's weird that the automatic process fails and if we run the same exact steps manually, it works. 😕
unfortunately, without a proper error message, there is nothing much we can do.

@betomoedano
Copy link

Same issue 😕

@cipolleschi
Copy link
Contributor

@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?

@betomoedano
Copy link

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

@ghost
Copy link
Author

ghost commented Mar 1, 2023

manual works for version 0.71.0 and 0.73.0

@sathiyaraj45
Copy link

@cipolleschi I tried you suggest command but I got the following error.

[!] Error installing boost
[!] /usr/bin/curl -f -L -o /var/folders/_y/1jlgk27j6xz72bwmny4f2_cw0000gq/T/d20230915-11391-i08i2k/file.tbz https://boostorg.jfrog.io/artifactory/main/release/1.76.0/source/boost_1_76_0.tar.bz2 --create-dirs --netrc-optional --retry 2 -A 'CocoaPods/1.12.1 cocoapods-downloader/1.6.3'

% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- 0:00:01 --:--:-- 0
99 104M 99 104M 0 0 2012k 0 0:00:53 0:00:53 --:--:-- 0
curl: (56) LibreSSL SSL_read: error:02FFF036:system library:func(4095):Connection reset by peer, errno 54

@cipolleschi
Copy link
Contributor

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

@sathiyaraj45
Copy link

We tried many time but we got the same error.

@sathiyaraj45
Copy link

we tried ping https://boostorg.jfrog.io but we unable to reach the data.

@popejrh19
Copy link

popejrh19 commented Sep 16, 2023 via email

@cortinico
Copy link
Contributor

Closing as stale + most likely related to a local network flakyness

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Platform: iOS iOS applications.
Projects
None yet
Development

No branches or pull requests

6 participants