So, we are currently trying to upload debug files to Sentry using GitHub Actions after a xcodebuild test command:
set -o pipefail && env NSUnbufferedIO=YES xcodebuild test -scheme Myscheme -workspace myworkspace.xcworkspace -destination 'platform=iOS Simulator,OS=17.0.1,name=iPhone 15 Pro' -enableCodeCoverage YES -allowProvisioningUpdates CODE_SIGNING_ALLOWED=NO | xcpretty
For this, we use the following sentry cli command:
sentry-cli debug-files upload --auth-token ${{ secrets.SENTRY_AUTH_TOKEN }} \
--include-sources \
--org myorg \
--project myproject \
$DWARF_DSYM_FOLDER_PATH/$DWARF_DSYM_FILE_NAME
But this command gives us an Permission denied (os error 13). Trying to change permissions in directory doesn't worked either.
And we can´t upload the debug files in the build phases because we can´t expose our Sentry token.
Some extra information: our workflow in GitHub Actions is running on macos-13.
Any ideas that could help me? Thanks!
Your dSYMs should be in the DerivedData folder on GH actions. Try running
The
DWARF_DSYM_FOLDER_PATHandDWARF_DSYM_FILE_NAMEare specific to Xcode. I wouldn't expect them to work in GH Actions. IfDerivedData/doesn't work, you can get their values by using the-showBuildSettingsxcodebuildflag.You can also specify a custom derived data location by using the
-derivedDataPathoption of xcodebuild.