realm-swift: Error installing RealmSwift
Realm framework version: ??? Realm Object Server version: ??? Xcode version: 12.0 iOS/OSX version: OS X 11.0 Beta BigSur Dependency manager + version: 1.9.3
When running pod install getting the issue:
[!] Error installing RealmSwift
[!] Failed to download ‘RealmSwift’: [!] /usr/bin/git C /var/folders/12/gkl91qgs1wz7731nbbvf3f9w0000gn/T/d202009252721-mas67c submodule update --init --recursive
Submodule path ‘Realm/ObjectStore’: checked out ‘e29b5515df8b8adfe2454424b78878bb63879307’ Submodule ‘Realm/ObjectStore’ (https://github.com/realm/realm-object-store.git) registered for path ‘Realm/ObjectStore’ Cloning into ‘/private/var/folders/12/gkl91qgs1wz7731nbbvf3f9w0000gn/T/d20200925-2721-mas67c/Realm/ObjectStore’… Submodule ‘external/catch’ (https://github.com/catchorg/Catch2) registered for path ‘Realm/ObjectStore/external/catch’ Cloning into ‘/private/var/folders/12/gkl91qgs1wz7731nbbvf3f9w0000gn/T/d20200925-2721-mas67c/Realm/ObjectStore/external/catch’… error: RPC failed; curl 18 transfer closed with outstanding read data remaining fatal: the remote end hung up unexpectedly fatal: clone of ‘https://github.com/catchorg/Catch2’ into submodule path ‘/private/var/folders/12/gkl91qgs1wz7731nbbvf3f9w0000gn/T/d20200925-2721-mas67c/Realm/ObjectStore/external/catch’ failed Failed to clone ‘external/catch’. Retry scheduled Cloning into ‘/private/var/folders/12/gkl91qgs1wz7731nbbvf3f9w0000gn/T/d20200925-2721-mas67c/Realm/ObjectStore/external/catch’… error: RPC failed; curl 18 transfer closed with outstanding read data remaining fatal: the remote end hung up unexpectedly fatal: clone of ‘https://github.com/catchorg/Catch2’ into submodule path ‘/private/var/folders/12/gkl91qgs1wz7731nbbvf3f9w0000gn/T/d20200925-2721-mas67c/Realm/ObjectStore/external/catch’ failed Failed to clone ‘external/catch’ a second time, aborting Failed to recurse into submodule path ‘Realm/ObjectStore’
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 20
- Comments: 30 (3 by maintainers)
Thanks @mir-dawn! I was able to install Realm using SwiftPM althought I had to tweak the command a bit to avoid breaking installation of other dependencies:
git config --global url."git@github.com:catchorg/Catch2".insteadOf https://github.com/catchorg/Catch2Same error is raised when installing using Xcode 12 and SwiftPM
This is a strange one. We had the same issue, and could reproduce the error both in Carthage and SwiftPM!
It looks to be an issue during the “git submodule update -v --init --recursive”, were we get a “RPC failed; curl 18 transfer closed with outstanding read data remaining” error. This issue have been seen before with large repos. Not sure who to “blame” here but I do actually not think this is a bug in Realm!
The most common suggestion to solve this to do a shallow clone, which is not possible in these cases.
But another suggestion is to use SSH instead of HTTPS! So what we did to solve it (as a temporary fix) was to change all git commands from HTTPS to SSH by adding the following to the global git config!
git config --global url.“git@github.com:”.insteadOf https://github.com/
This will force git to use SSH instead of HTTPS for GitHub, and that resolved the issue for us.
Remember to remove this config again later, to avoid possible problems later. Do not see this as a permanent fix 😉
It’s back 🎉🎉🎉🎉🎉
Same error when installing using Xcode 11.7 and SwiftPM.
@MeGaPk looks like you are missing a SSH key.
https://docs.github.com/en/github/authenticating-to-github/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent
Facing the same issue with Xcode 12 GM and SwiftPM
Same error with Xcode 12.0.1 (12A7300) and SwiftPM. Deleting the derived data folder and changing the global git
http.postBuffersize did not fixed the problem.Facing the same problem using xcode 12 + SPM with Realm v4.x.x (latest v4).
Not being able to use ssh (continuous integration over a server with not enough ssh rights), this still remains an issue.
I hope the Realm team can fix this quickly 🤞
same error on pod ‘Realm’. Yesterday was OK. Only this problem started today
Apologies for the comment I left that was supposed to be on an internal debugging thread at github 🙏 I’ve deleted my comment here and I apologize for any confusion.
Closing as this is Github related & also looks to be resolved.
Hello! I tried this, but get errors: