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

Problem installing CocoaPods on MacOS #138293

Closed
2 tasks done
kaimacuser opened this issue Nov 11, 2023 · 6 comments
Closed
2 tasks done

Problem installing CocoaPods on MacOS #138293

kaimacuser opened this issue Nov 11, 2023 · 6 comments
Labels
in triage Presently being triaged by the triage team waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds

Comments

@kaimacuser
Copy link

Is there an existing issue for this?

Steps to reproduce

Try to install cocoapods via (macOS Sonoma 14.1.1 on MacBook Air and MacMini):
sudo gem install cocoapods

Actual results

It trys to install cocoapods but runs into an error because the version of ruby, that is delivered with macOS, seems to be too old for installing the latest version of cocoapods.

The solution for me was to install an older version of cocoapods which seems to be based on Ruby 2.6.* (the version macOS ist delivered with). While executing the command I was asked to install a few other things, so the final order was:

  1. sudo gem install drb -v 2.0.5
  2. sudo gem install activesupport -v 6.1.7.6
  3. sudo gem install cocoapods -v 1.13.0

Logs

Logs
ERROR:  Error installing cocoapods: There are no versions of cocoapods-downloader (>= 2.0) compatible with your Ruby & RubyGems. Maybe try installing an older version of the gem you're looking for? cocoapods-downloader requires Ruby version >= 2.7.4. The current ruby version is 2.6.10.210.

Flutter Doctor output

Flutter just complained that cocoapods is not installed - which actually wasn't the case

@ShubhamKNIT
Copy link

ShubhamKNIT commented Nov 12, 2023

While working on flutter I also encountered the same issue recently but was able to tackle it and install cocoapods required for macOS. Here is the solution:

brew install ruby

This installed me the ruby required and then i followed the order to install the cocoapods.

@dam-ease dam-ease added the in triage Presently being triaged by the triage team label Nov 13, 2023
@dam-ease
Copy link

Thanks for your input @kaimacuser.
@kaimacuser. Can you try out #138293 (comment) to see if it works in your case?

@dam-ease dam-ease added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Nov 13, 2023
@kaimacuser
Copy link
Author

Thank you for the quick answer!
I haven't installed brew yet (I should definitely catch up)

I have found an open issue on the cocoapods GitHub

Their advise was to install a newer version of ruby.

@github-actions github-actions bot removed the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Nov 13, 2023
@ShubhamKNIT
Copy link

Yeah, Let me know if it works for you.

@dam-ease dam-ease added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Nov 14, 2023
Copy link

github-actions bot commented Dec 5, 2023

Without additional information, we are unfortunately not sure how to resolve this issue. We are therefore reluctantly going to close this bug for now.
If you find this problem please file a new issue with the same description, what happens, logs and the output of 'flutter doctor -v'. All system setups can be slightly different so it's always better to open new issues and reference the related ones.
Thanks for your contribution.

@github-actions github-actions bot closed this as completed Dec 5, 2023
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
in triage Presently being triaged by the triage team waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds
Projects
None yet
Development

No branches or pull requests

3 participants