Post marked as solved
Click to stop watching this thread.
You have stopped watching this post. Click to start watching again.
Post marked as solved with 5 replies, 0 views
I suspect the answer here is that Instruments can't attach to unsigned code and executable targets build by the Swift Package Manager tooling doesn't sign code.
This makes sense because it's meant to be open source and cross platform, yet code signing is a Apple thing.
As a workaround, I created a simple Command Line Tool Xcode project and added my Swift Package as a dependency, with the tool's main.swift just calling into the package. Xcode will happily code sign everything and Instruments runs just fine.
I suppose an open/related question is: can Instruments/macOS be persuaded to instrument unsigned code?