Hi,
Im using Carthage to update the library of facebook-ios-sdk, but it keeps showing me the same problem all the time.
In Cartfile add this:
github "facebook/facebook-ios-sdk"
problem:
"xcodebuild timed out while trying to read SmoketestSPM.xcodeproj 馃槶"
Hi.
Could you please provide the carthage command you ran along with the full output of the command? Thanks!
carthage update --no-use-binaries --platform iOS
Not able to reproduce. If you delete the Carthage checkout directory and the .resolved file and rerun the command are you able to reproduce?
I'm facing the same issue. Delete Carthage repository does not solve the problem and Removes Cartfile.resolved isn't an option.
@yoni89 what directory are you running the command from? Also, out of curiosity are you running any other tools that modify the directory structure or mess with xcode targets? Also why is removing Cartfile.resolved or at least the lines of Cartfile.resolved that reference the SDK not an option?
Additionally, Building only facebook-ios-sdk from checkouts folder results in:
carthage build --no-skip-current --platform iOS
* xcodebuild output can be found in /var/folders/hy/5szzcfdn2mncf68j9yymwxfm0000gn/T/carthage-xcodebuild.qKmJwC.log
Building scheme "OCMock iOS" in OCMock.xcodeproj
Building scheme "OHHTTPStubs iOS Framework" in OHHTTPStubs.xcworkspace
* Skipped building Tweaks due to the error:
Dependency "Tweaks" has no shared framework schemes for any of the platforms: iOS
If you believe this to be an error, please file an issue with the maintainers at https://github.com/facebook/Tweaks/issues/new
xcodebuild timed out while trying to read SmoketestSPM.xcodeproj 馃槶
Removing facebook-ios-sdk from Carfile.resolved and run carthage update, result at same response.
@joesus
I have changed to apple package manager which you also support, facebook-ios-sdk currently doesn't work on carthage for me.
@yoni89 will investigate this more. Glad we were able to provide another channel!
I have same issue. My temporarily resolution:
Remove "facebook-ios-sdk" form Cartfile, and update completed. Then add back "facebook-ios-sdk" to Cartfile, Update it separately, finally done.
As I was unable to reproduce I would advise trying @bennettyuan18's approach. If that does not work you may try using a different distribution channel such as SPM or Cocoapods. Also, based on the number of responses to this issue it seems like this is a local configuration issue. If you are able to reproduce this in a small sample app, attach that and we can look into reopening. Thanks!
My resolution:
1) Open "SmoketestSPM.xcodeproj" (... Carthage/Checkouts/facebook-ios-sdk/samples/SmoketestSPM/SmoketestSPM.xcodeproj)
2) Wait for SMP to load a dependency (Carthage can't wait for the dependency to download and it is cause of the timeout)
3) And now you can use "carthage update"
My resolution:
1. Open "SmoketestSPM.xcodeproj" (... Carthage/Checkouts/facebook-ios-sdk/samples/SmoketestSPM/SmoketestSPM.xcodeproj) 2. Wait for SMP to load a dependency (Carthage can't wait for the dependency to download and it is cause of the timeout) 3. And now you can use "carthage update"
Thank your answer. It helps for me
My resolution:
- Open "SmoketestSPM.xcodeproj" (... Carthage/Checkouts/facebook-ios-sdk/samples/SmoketestSPM/SmoketestSPM.xcodeproj)
- Wait for SMP to load a dependency (Carthage can't wait for the dependency to download and it is cause of the timeout)
- And now you can use "carthage update"
Thank you. It worked for me
Does anyone know the root cause of this issue? It's really annoying to have to do this every time.
Does anyone know the root cause of this issue? It's really annoying to have to do this every time.
Root cause is that Carthage build will greedy-search the repo for any Xcode project files / targets, this means it will pick up sample projects because they have project files with valid targets. You can avoid this by using Carthage's no-build flag which will pull prebuilt binaries from the latest release, or by avoiding Carthage entirely, using the XCFrameworks uploaded to the latest release, or Swift Package Manager, or CocoaPods.
after a bit of research, this article from circle CI:
https://support.circleci.com/hc/en-us/articles/360044709573-Swift-Package-Manager-fails-to-clone-from-private-Git-repositories
xcodebuild does not conform to the system ssh config and does not access the keys CircleCI stores in ssh-agent
the same applies to local repository, so I was able to work around this by running the following as part of my third party setup code:
sudo defaults write com.apple.dt.Xcode IDEPackageSupportUseBuiltinSCM YES
rm ~/.ssh/id_rsa || true
for ip in $(dig @8.8.8.8 bitbucket.org +short); do ssh-keyscan bitbucket.org,$ip; ssh-keyscan $ip; done 2>/dev/null >> ~/.ssh/known_hosts || true
for ip in $(dig @8.8.8.8 github.com +short); do ssh-keyscan github.com,$ip; ssh-keyscan $ip; done 2>/dev/null >> ~/.ssh/known_hosts || true
It seems like this is sufficiently answered. Closing conversation. If there is a new or more specific issue around this please open a new issue with supporting details. Thanks!
Most helpful comment
My resolution:
1) Open "SmoketestSPM.xcodeproj" (... Carthage/Checkouts/facebook-ios-sdk/samples/SmoketestSPM/SmoketestSPM.xcodeproj)
2) Wait for SMP to load a dependency (Carthage can't wait for the dependency to download and it is cause of the timeout)
3) And now you can use "carthage update"