-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Document IL2125 and IL3058 transitive reference compatibility warnings #50266
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Co-authored-by: sbomer <787361+sbomer@users.noreply.github.com>
Co-authored-by: sbomer <787361+sbomer@users.noreply.github.com>
Co-authored-by: sbomer <787361+sbomer@users.noreply.github.com>
Co-authored-by: sbomer <787361+sbomer@users.noreply.github.com>
Co-authored-by: sbomer <787361+sbomer@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR documents two new analyzer warnings (IL2125 and IL3058) that verify transitive dependency compatibility with trimming and Native AOT. These warnings are emitted when verification properties are enabled and referenced assemblies lack the appropriate compatibility metadata attributes.
Key changes:
- Adds IL2125 warning documentation for trim compatibility verification
- Adds IL3058 warning documentation for AOT compatibility verification
- Updates conceptual guides with new verification properties and usage guidance
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
docs/core/deploying/trimming/trim-warnings/il2125.md |
New warning documentation for IL2125, explaining when it's emitted and how to fix it |
docs/core/deploying/native-aot/warnings/il3058.md |
New warning documentation for IL3058, explaining AOT compatibility verification |
docs/core/deploying/trimming/prepare-libraries-for-trimming.md |
Adds section on VerifyReferenceTrimCompatibility property with usage guidance |
docs/core/deploying/native-aot/index.md |
Adds section on VerifyReferenceAotCompatibility property, including note about .NET 10 introduction |
Co-authored-by: sbomer <787361+sbomer@users.noreply.github.com>
Co-authored-by: sbomer <787361+sbomer@users.noreply.github.com>
Co-authored-by: Genevieve Warren <24882762+gewarren@users.noreply.github.com>
Co-authored-by: sbomer <787361+sbomer@users.noreply.github.com>
Co-authored-by: sbomer <787361+sbomer@users.noreply.github.com>
Summary
Documents new analyzer warnings IL2125 and IL3058 introduced in dotnet/runtime#118180 for verifying transitive dependency compatibility with trimming and Native AOT.
New warning documentation:
IL2125: Referenced assembly is not annotated for trim compatibility - emitted whenVerifyReferenceTrimCompatibility=trueand a referenced assembly lacksIsTrimmablemetadataIL3058: Referenced assembly is not annotated for AOT compatibility - emitted whenVerifyReferenceAotCompatibility=trueand a referenced assembly lacksIsAotCompatiblemetadataUpdated conceptual documentation:
VerifyReferenceTrimCompatibilityproperty to trim preparation guideVerifyReferenceAotCompatibilityproperty to Native AOT overviewIsAotCompatiblemetadata was introduced in .NET 10Documentation approach:
ai-usage: ai-assisteddisclosure in frontmatter per .NET documentation guidelinesPublishTrimmed/IsTrimmablefor trim warnings, andPublishAot/IsAotCompatiblefor AOT warningsBoth properties are opt-in, allowing library authors to enforce that all dependencies explicitly declare trim/AOT compatibility:
Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.
Internal previews