f-meloni / danger-swift-coverage

Show the coverage of the modified/created files on your PRs.
MIT License
85 stars 20 forks source link

Xcode 11.2.1 cannot read the new .xcresult format #18

Open duyquang91 opened 4 years ago

duyquang91 commented 4 years ago

It seems like the same issue has been fixed for Xcode 11.1. Now it is happening on the Xcode 11.2.1, could you please take a look?

f-meloni commented 4 years ago

Ok let me have a look

duyquang91 commented 4 years ago

@f-meloni I don't use the SPM, I use the marathon instead, any solution for that?

f-meloni commented 4 years ago

I've tried it with both -resultBundlePath build/results and without it in the xcodebuild command, it works in both cases with XCode 11.2.1

ecerney commented 4 years ago

Is this now an issue in Xcode 11.3 again? I'm getting Requested but did not find extension point with identifier Xcode.IDEFoundation.IDEResultKitSerializationConverter when passing an xcresult

f-meloni commented 4 years ago

@ecerney I've updated travis on https://github.com/f-meloni/danger-swift-coverage/pull/20 to xcode 11.3, and looks working, then should work in the previous versions too

el-hoshino commented 4 years ago

I've got the same error with Xcode 11.5 on Bitrise:

+ danger-swift ci
objc[16991]: Class _TtC7OctoKit4File is implemented in both /usr/local/Cellar/danger-swift/3.3.2/lib/danger/libDanger.dylib (0x113c81778) and /Users/vagrant/.danger-swift/Scripts/Cache/-Users-vagrant-git-_dangerfile_imports/.build/x86_64-apple-macosx/debug/libDangerDependencies.dylib (0x113a21c28). One of the two will be used. Which one is .

objc[16991]: Class _TtC7OctoKit4Gist is implemented in both /usr/local/Cellar/danger-swift/3.3.2/lib/danger/libDanger.dylib (0x113c81a30) and /Users/vagrant/.danger-swift/Scripts/Cache/-Users-vagrant-git-_dangerfile_imports/.build/x86_64-apple-macosx/debug/libDangerDependencies.dylib (0x113a21ed8). One of the two will be used. Which one is .
objc[16991]: Class _TtC7OctoKit5Issue is implemented in both /usr/local/Cellar/danger-swift/3.3.2/lib/danger/libDanger.dylib (0x113c81e60) and /Users/vagrant/.danger-swift/Scripts/Cache/-Users-vagrant-git-_dangerfile_imports/.build/x86_64-apple-macosx/debug/libDangerDependencies.dylib (0x113a22320). One of the two will be used. Which one is .
objc[16991]: Class _TtC7OctoKit5Label is implemented in both /usr/local/Cellar/danger-swift/3.3.2/lib/danger/libDanger.dylib (0x113c822b8) and /Users/vagrant/.danger-swift/Scripts/Cache/-Users-vagrant-git-_dangerfile_imports/.build/x86_64-apple-macosx/debug/libDangerDependencies.dylib (0x113a22730). One of the two will be used. Which one is undefined.
objc[16991]: Class _TtC7OctoKit9Milestone is implemented in both /usr/local/Cellar/danger-swift/3.3.2/lib/danger/libDanger.dylib (0x113c82470) and /Users/vagrant/.danger-swift/Scripts/Cache/-Users-vagrant-git-_dangerfile_imports/.build/x86_64-apple-macosx/debug/libDangerDependencies.dylib (0x113a228d8). One of the two will be used. Which one is undefined.
objc[16991]: Class _TtC7OctoKit11PullRequest is implemented in both /usr/local/Cellar/danger-swift/3.3.2/lib/danger/libDanger.dylib (0x113c82830) and /Users/vagrant/.danger-swift/Scripts/Cache/-Users-vagrant-git-_dangerfile_imports/.build/x86_64-apple-macosx/debug/libDangerDependencies.dylib (0x113a22ca0). One of the two will be used. Which one is undefined.
objc[16991]: Class _TtC7OctoKit10Repository is implemented in both /usr/local/Cellar/danger-swift/3.3.2/lib/danger/libDanger.dylib (0x113c82d50) and /Users/vagrant/.danger-swift/Scripts/Cache/-Users-vagrant-git-_dangerfile_imports/.build/x86_64-apple-macosx/debug/libDangerDependencies.dylib (0x113a231b0). One of the two will be used. Which one is undefined.
objc[16991]: Class _TtC7OctoKit4User is implemented in both /usr/local/Cellar/danger-swift/3.3.2/lib/danger/libDanger.dylib (0x113c83100) and /Users/vagrant/.danger-swift/Scripts/Cache/-Users-vagrant-git-_dangerfile_imports/.build/x86_64-apple-macosx/debug/libDangerDependencies.dylib (0x113a23578). One of the two will be used. Which one is undefined.

2020-07-06 21:50:08.298 xccov[16996:69434] Requested but did not find extension point with identifier Xcode.IDEFoundation.IDEResultKitSerializationConverter

The code I'm running is something like:

let bitriseXCResultPath = Process.runShell("echo $BITRISE_XCRESULT_PATH")
xcodeBuildCoverage(.xcresultBundle(bitriseXCResultPath), minimumCoverage: 60)

$BITRISE_XCRESULT_PATH is Xcode Test step's output which refers to the path of .xcresult file

f-meloni commented 4 years ago

@el-hoshino Please verify that the path has .xcresult at the end, the newer version doesn't work with the folder path

PS. You can probably use ProcessInfo.processInfo.environment["BITRISE_XCRESULT_PATH"] to get the path

el-hoshino commented 4 years ago

@f-meloni I tried ProcessInfo.processInfo.environment["BITRISE_XCRESULT_PATH"] and it worked! Thanks a lot!!