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

react-native init is failing #40737

Closed
cstayyab opened this issue Oct 9, 2023 · 7 comments
Closed

react-native init is failing #40737

cstayyab opened this issue Oct 9, 2023 · 7 comments

Comments

@cstayyab
Copy link

cstayyab commented Oct 9, 2023

Description

New Project creation fails due to CocoaPods/CocoaPods#12081

React Native Version

0.72.5

Output of npx react-native info

info Fetching system and libraries information...
System:
  OS: macOS 14.0
  CPU: (16) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
  Memory: 526.26 MB / 16.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 18.12.1
    path: ~/.nvm/versions/node/v18.12.1/bin/node
  Yarn:
    version: 1.22.19
    path: ~/.nvm/versions/node/v18.12.1/bin/yarn
  npm:
    version: 8.19.2
    path: ~/.nvm/versions/node/v18.12.1/bin/npm
  Watchman:
    version: 2023.10.02.00
    path: /usr/local/bin/watchman
Managers:
  CocoaPods:
    version: 1.13.0
    path: /Users/tayyab/.gem/bin/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 23.0
      - iOS 17.0
      - macOS 14.0
      - tvOS 17.0
      - watchOS 10.0
  Android SDK: Not Found
IDEs:
  Android Studio: 2022.3 AI-223.8836.35.2231.10811636
  Xcode:
    version: 15.0/15A240d
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 11.0.20.1
    path: /usr/bin/javac
  Ruby:
    version: 3.2.0
    path: /Users/tayyab/.rbenv/shims/ruby
npmPackages:
  "@react-native-community/cli": Not Found
  react:
    installed: 18.2.0
    wanted: 18.2.0
  react-native:
    installed: 0.72.5
    wanted: 0.72.5
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: false
iOS:
  hermesEnabled: Not found
  newArchEnabled: Not found

Steps to reproduce

Just create new project using

npx react-native init test

Snack, screenshot, or link to a repository

https://github.com/cstayyab/react-native-issue-40737

image
@github-actions github-actions bot added Needs: Repro This issue could be improved with a clear list of steps to reproduce the issue. and removed Needs: Repro This issue could be improved with a clear list of steps to reproduce the issue. labels Oct 9, 2023
@mamicicekel
Copy link

I'm also getting the same error, and I haven't been able to solve it.

@AdityaGoyal1999
Copy link

Even I'm getting the same error for the past 3 days. The bundling is not happening properly

@cstayyab
Copy link
Author

Workaround:

When react-native init fails at cocoapods installation, do the following steps:

  1. Go to your project directory and open Gemfile
  2. Replace Cocoapods version with 1.13
  3. Insert following line at the end of Gemfile : gem 'activesupport', '~> 7.0.8'
  4. Run bundle install in your project directory
  5. Go to ios directory in your project
  6. Run bundle exec pod install

Now proceed as you would if react-native init was successful

@mamicicekel
Copy link

Workaround:

When react-native init fails at cocoapods installation, do the following steps:

  1. Go to your project directory and open Gemfile
  2. Replace Cocoapods version with 1.13
  3. Insert following line at the end of Gemfile : gem 'activesupport', '~> 7.0.8'
  4. Run bundle install in your project directory
  5. Go to ios directory in your project
  6. Run bundle exec pod install

Now proceed as you would if react-native init was successful

It's working successfully this way, but when I create another project, I encounter the same error. Isn't there a permanent solution?

@takameyer
Copy link

The fix has been made, it just needs to be released.

@AdityaGoyal1999
Copy link

Workaround:

When react-native init fails at cocoapods installation, do the following steps:

  1. Go to your project directory and open Gemfile
  2. Replace Cocoapods version with 1.13
  3. Insert following line at the end of Gemfile : gem 'activesupport', '~> 7.0.8'
  4. Run bundle install in your project directory
  5. Go to ios directory in your project
  6. Run bundle exec pod install

Now proceed as you would if react-native init was successful

I'm still facing an issue when I run bundle install

In Gemfile: cocoapods was resolved to 1.13.0, which depends on cocoapods-core was resolved to 1.13.0, which depends on typhoeus was resolved to 1.4.0, which depends on ethon was resolved to 0.16.0, which depends on ffi

@cortinico
Copy link
Contributor

Duplicates #39832

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

No branches or pull requests

5 participants