Open UkuLoskit opened 7 years ago
Hi, thanks for letting us know. If I understand correctly there is a fix already underway, so once it gets merged, we should be fine, right?
It looks like it could use some prodding on xcpretty's side since the pull request has been been open for almost a year without any comments.
Maybe we should disable the xcpretty
integration by default? See also #759
Hi @jvillard,
In my case, I had two projects, first is a CocoaPods project, it can build success without xcpretty
and got correct report by infer.
Build with commnad:
infer --skip-analysis-in-path Pods -- xcodebuild -workspace Example/XX-SDK.xcworkspace -scheme XX-SDK-Example -configuration Debug -sdk iphonesimulator clean build
The second project is a App project that had a Watch extension, it can build success with --xcpretty
flag, but got some error when reading file from DerivedData
.
Build with commannd:
# Build success, but infer capture did not finish successfully.
infer --xcpretty --skip-analysis-in-path Pods -- xcodebuild -workspace ./iPhone-Project.xcworkspace -scheme iPhone clean build
# Build fail when compile a file look like related to Watch Extension
infer --skip-analysis-in-path Pods -- xcodebuild -workspace ./iPhone-Project.xcworkspace -scheme iPhone clean build
Error message:
CompileC MyFolderPath/DerivedData/iPhone-fqtxfkpooicdeabsgdvplwuwcxrj/Build/Intermediates.noindex/Pods.build/Debug-watchos/Mixpanel-watchOS2.0.build/Objects-normal/arm64_32/SessionMetadata.o MyFolderPath/Pods/Mixpanel/Mixpanel/SessionMetadata.m normal arm64_32 objective-c com.apple.compilers.llvm.clang.1_0.compiler
xcpretty
to build my project?xcpretty
, how to build my App target that has a Watch extension?I found and issue comment here, but I have no idea what the flags really are.
Any suggestions? Really appreciate.
@marcuswu0814 have you tried the commands specified here?
xcodebuild <your build options> | tee xcodebuild.log
xcpretty -r json-compilation-database -o compile_commands.json < xcodebuild.log > /dev/null
infer run --skip-analysis-in-path Pods --clang-compilation-db-files-escaped compile_commands.json
Hello!
This issue affects Infer as Infer seems to be relying it to gather the list of files to be analyzed.
https://github.com/supermarin/xcpretty/pull/230