Repository navigation
Add the analyzer and package-reference checks - #185
Merged
Merged
Conversation
CA1031 (no general catch) and CA2007 (ConfigureAwait) are warnings in src/, errors in CI; src/ had no violations. A target in src/Directory.Build.targets fails the build when a src/ project references a package its allow-list doesn't name: by default the Core and provider list from ADR-0004 (BCL packages on netstandard2.0 only); Diagnostics and the integration packages set theirs in the csproj. ADR-0002 and ADR-0004 name the checks in their Confirmation; CLAUDE.md and reviewer.md point to them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #110
What
src/.editorconfig(new,src/only): CA1031 (no generalcatch) and CA2007 (ConfigureAwait) are warnings; CI'sTreatWarningsAsErrorsmakes them errors.src/had no violations, so CA2007 is on (the issue's "if src is clean").src/Directory.Build.targets:CheckPackageReferenceAllowListruns before each inner build's compile and fails when asrc/project references a package its allow-list (OpenUrzednikAllowedPackageReferences) doesn't name. SDK-implied references (IsImplicitlyDefined) and build-only ones (PrivateAssets="all", NBGV) are skipped.System.Text.Json,System.Net.Http.Json,Microsoft.Bcl.TimeProvider,Microsoft.Bcl.HashCodeon netstandard2.0.OpenUrzednik.Diagnostics:System.Diagnostics.DiagnosticSourceon netstandard2.0 only.OpenUrzednik.Nbp.DependencyInjection:Microsoft.Extensions.Http,Microsoft.Extensions.Options,Polly.Core.OpenUrzednik.Extensions.Logging:Microsoft.Extensions.Logging.Abstractions.src/project, not only Core and Nbp as the issue says (maintainer decision).2026-10-30note. CLAUDE.md (catch,PackageReference,ConfigureAwaitrules) and reviewer.md point to them.Checks
catchand anawaitwithoutConfigureAwaitproduced both warnings (file deleted).System.Text.Jsonreference in Core failednet8.0andnet10.0with the new error and passednetstandard2.0(csproj restored).dotnet build OpenUrzednik.slnx: 0 warnings, 0 errors.-f net10.0and-f net472: all projects pass (21 explicit real-API tests not run).dotnet format --verify-no-changes: clean.dotnet pack OpenUrzednik.Packages.slnf -c Release -p:ContinuousIntegrationBuild=true: pass.revieweragent: no blocking findings; its corrections (the editorconfig comment named the wrong MSBuild property; ADR-0004 wording on the lists being an approved subset of the table) are applied.🤖 Generated with Claude Code