Skip to content

Trimmed iOS and Mac Catalyst builds upload pre-trim PDBs that match nothing in the app #5728

Closed

Description

@jamescrosswell

For iOS and Mac Catalyst apps, UploadDebugInfoToSentry in src/Sentry/buildTransitive/Sentry.targets uploads everything in $(OutputPath) plus the trimmer's PDBs: linked/*.pdb on main, while version7 prefers postprocessed-assemblies/*.pdb (#5725). When the trimmer rewrites an assembly, the copy in $(OutputPath) is the pre-trim build, so its PDB ID doesn't match anything in the app bundle. Symbolication still works, because the trimmer's copy is uploaded too, but each of these is an upload that can never match.

I measured this on a Release Mac Catalyst build of Sentry.Samples.Maui (.NET 11 RC 2, with #5725) by comparing the CodeView PDB IDs of the assemblies in the app bundle with the IDs of the uploaded PDBs. All 13 shipped assemblies were covered. In addition, 5 uploaded PDBs matched nothing that ships: the $(OutputPath) copies of Sentry, Sentry.Maui, Sentry.Extensions.Logging, Sentry.Bindings.Cocoa and the app itself. An untrimmed iOS simulator build had no such extras. I didn't measure device builds, but they're trimmed too, so I'd expect them to look like the Mac Catalyst one.

Fix

When a trimmer output directory exists, take PDBs only from it, not from $(OutputPath). $(OutputPath) still has to be uploaded for the native dSYMs (libcoreclr, SentryObjC, the app executable), so either leave the PDB types out for that path (a second sentry-cli call) or list the dSYMs explicitly.

Fix this on main, using the directory logic from #5725 ("postprocessed-assemblies when it exists, else linked"). Then main and version7 end up with the same code, and the next merge of main into version7 resolves trivially.

cli.Tests.ps1 compares uploaded file names with Sort-Object -Unique, so it can't tell these apart. A test needs to compare debug IDs, as the measurement above did.

Activity

  1. linear-code commented on Oct 14, 2026

    @linear-code
  2. added a commit that references this issue on Oct 19, 2026
    8c4723d
  3. added 2 commits that reference this issue on Oct 20, 2026
    4261436
    09794d8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

.NETPull requests that update .net codeBugSomething isn't workingPlatform: iOS

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions