Skip to content

Build: stop packing an empty symbol package - #70

Open
phmatray wants to merge 1 commit into
devfrom
fix/inert-symbol-package
Open

Build: stop packing an empty symbol package#70
phmatray wants to merge 1 commit into
devfrom
fix/inert-symbol-package

Conversation

@phmatray

@phmatray phmatray commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

What

IncludeSymbols + SymbolPackageFormat=snupkg are inert here and have been since the day DotNet.ReproducibleBuilds was added: it sets DebugType=embedded, so the portable PDB lives inside the assembly and no separate .pdb is ever produced.

The published FastComponents.1.0.0.snupkg is a 3.5 KB shell — 4 files, none of them a .pdb:

_rels/.rels
FastComponents.nuspec
[Content_Types].xml
package/services/metadata/core-properties/….psmdcp

Why it never broke a release

By accident. The artifact step uploads ${{ env.NuGetDirectory }}/*.nupkg, and *.nupkg does not match .snupkg — so the empty symbol package never left the create_nuget runner and deploy never tried to push it.

That makes this a trap: anyone tightening that filter to carry symbols along turns a silent no-op into a failed publish. nuget.org answers 400 The package does not contain any symbol (.pdb) files. That is exactly what happened on PlayBlazor, which inherited this configuration — the .nupkg published, then deploy went red on the symbol push.

The fix

Remove both properties rather than force DebugType=portable to feed a symbol server. Embedded is the better trade for a component library: consumers get symbols and Source Link with no symbol-server configuration at all.

Nothing is lost from what is already on nuget.orgFastComponents.1.0.0's assembly carries its embedded PDB (MPDB blob verified inside the pushed package).

Verified

A Release build of src/FastComponents now produces the .nupkg alone, no empty .snupkg beside it.

Not affected

VirtualFileSystem declares neither property, so it never produced a symbol package and has nothing to fix here.

🤖 Generated with Claude Code

https://claude.ai/code/session_01D7hy3BpcmrBsEfqE9uGrNp

DotNet.ReproducibleBuilds sets DebugType=embedded, so the portable PDB lives inside the
assembly and no separate .pdb is ever emitted. `IncludeSymbols` + `SymbolPackageFormat=snupkg`
have therefore been packing a shell containing nothing but a nuspec: the shipped
FastComponents.1.0.0.snupkg is 3.5 KB across 4 files, not one of them a .pdb.

It never broke a release only by accident. The artifact step uploads `*.nupkg`, and that
pattern does not match `.snupkg`, so the empty symbol package never left the create_nuget
runner. Anyone "fixing" that filter to carry symbols along would turn a silent no-op into a
failed publish — nuget.org answers 400 "The package does not contain any symbol (.pdb) files"
to an empty snupkg. That is exactly what happened on Atypical-Consulting/PlayBlazor, which
inherited this configuration.

Removes both properties rather than forcing DebugType=portable to feed a symbol server:
embedded means consumers get symbols and Source Link with no symbol-server setup at all.

Nothing is lost from what is already published — FastComponents.1.0.0's assembly carries its
embedded PDB (MPDB blob verified in the pushed package).

Verified: a Release build of src/FastComponents now produces the .nupkg alone.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01D7hy3BpcmrBsEfqE9uGrNp
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant