fix: resolve NU1506 duplicate package errors and update SDK to 1.6.29 - #3
Conversation
This commit fixes the systematic build failures caused by duplicate PackageVersion errors: **Problem 1: Duplicate PackageVersion (NU1506)** - ANcpLua.Analyzers, Microsoft.CodeAnalysis.BannedApiAnalyzers, JonSkeet.RoslynAnalyzers, and Microsoft.Sbom.Targets were defined both in ANcpLua.NET.Sdk AND Directory.Packages.props - This caused NU1506 errors when building with PublishAot=true **Problem 2: Outdated SDK versions** - SDK packages were at 1.6.26, but latest is 1.6.29 (3 versions behind) **Problem 3: No Dependabot configuration** - Without Dependabot, SDK packages became out of sync and required manual updates **Changes:** 1. ✅ Created .github/dependabot.yml with SDK grouping - Groups all ANcpLua.NET.Sdk* packages together - Prevents version mismatches in future updates 2. ✅ Updated SDK versions in global.json: 1.6.26 → 1.6.29 - ANcpLua.NET.Sdk - ANcpLua.NET.Sdk.Test - ANcpLua.NET.Sdk.Web 3. ✅ Cleaned Directory.Packages.props - Removed duplicate PackageVersion entries (Update="...") - Added documentation comment explaining which packages are managed by the SDK - Kept ANcpLua.Roslyn.Utilities* as they are project-specific **Result:** - NU1506 duplicate package errors are resolved - Dependabot will keep SDK packages synchronized - Future updates will be grouped, preventing partial updates Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Summary of ChangesHello @ANcpLua, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! Dieser Pull Request behebt kritische Build-Probleme, die durch doppelte Paketversionen und veraltete SDKs verursacht wurden. Durch die Aktualisierung der SDK-Versionen und die Entfernung redundanter Pakete wird die Build-Stabilität wiederhergestellt. Zusätzlich wird Dependabot konfiguriert, um zukünftige Versionskonflikte proaktiv zu verhindern und die Abhängigkeiten automatisch auf dem neuesten Stand zu halten, was die Wartung vereinfacht und die Zuverlässigkeit des Projekts verbessert. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
|
Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. WalkthroughUpdates add Dependabot config, bump three ANcpLua.NET.Sdk msbuild-sdks to 1.6.29, remove centrally-versioned analyzer and SBOM package entries from package props, adjust warnings settings, and add a detailed internal gRPC implementation analysis document. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes 🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Code Review
Dieser Pull Request behebt die NU1506-Fehler durch das Entfernen doppelter Paketdefinitionen und aktualisiert gleichzeitig das ANcpLua.NET.Sdk auf Version 1.6.29. Zusätzlich wird Dependabot konfiguriert, um zukünftige Abhängigkeits-Updates zu automatisieren. Die Änderungen sind gut strukturiert und die hinzugefügten Kommentare in Directory.Packages.props sind sehr hilfreich, um zukünftige Fehler zu vermeiden. Ich habe einen kleinen Verbesserungsvorschlag für die Dependabot-Konfiguration, um sie konsistent mit den Änderungen an den Paketabhängigkeiten zu halten.
| patterns: | ||
| - "ANcpLua.Roslyn.Utilities*" | ||
| - "ANcpLua.Analyzers" | ||
| # Group OpenTelemetry packages |
There was a problem hiding this comment.
In dieser Konfiguration wird ANcpLua.Analyzers für Dependabot-Updates gruppiert. Laut den Änderungen in Directory.Packages.props wird dieses Paket jedoch jetzt vom ANcpLua.NET.Sdk verwaltet und sollte nicht mehr direkt referenziert werden, um Duplikatfehler zu vermeiden.
Um die Konfiguration konsistent zu halten und zukünftige Verwirrung zu vermeiden, empfehle ich, ANcpLua.Analyzers aus dieser Dependabot-Gruppe zu entfernen. Dependabot sollte keine Pakete verfolgen, die transitiv verwaltet werden.
**Problem:** - WarningsAsErrors referenced VSTHRD100, VSTHRD002, VSTHRD003 - NoWarn referenced VSTHRD111 - These analyzers were never installed → invalid references **Changes:** 1. ✅ Directory.Build.props - Removed VSTHRD100, VSTHRD002, VSTHRD003 from WarningsAsErrors - Added comment explaining why (analyzer never installed) - Kept critical async/dispose rules: CA1816, CA2012, CA2016 2. ✅ tests/Directory.Build.props - Removed VSTHRD111 from NoWarn - Kept CA1707 (underscores in test names) and xUnit1051 3. ✅ docs/internal/grpc-implementation-analysis.md - Added comprehensive gRPC implementation documentation - Documented current approach vs. modern alternatives (LightProto, MemoryPack) - Provides decision matrix for serialization choices - Reference for future gRPC architecture decisions **Result:** - No more warnings about missing analyzer packages - Cleaner build output - Better documentation for gRPC implementation strategy Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
… cost ModelPricingRow already carried CacheReadCost/CacheWriteCost/ReasoningCost columns but ComputeCost only priced input+output, and no span-level cache/ reasoning token fields existed -- so all three columns were dead. Transpiled from yurekami/aegis CostEntry.compute_cost (harvest #7). End-to-end wiring (sanctioned regenerate path, no hand-edited .g.cs): - collector-semantic-policy.json: projectionConstants + spanHotAttributeKeys for gen_ai.usage.cache_read/cache_creation.input_tokens + reasoning.output_tokens - regenerated CollectorSemanticAttributeCatalog.g.cs (3 new consts) - StorageAttributeProjection + SpanHotAttributeProjection: extract the 3 fields - SpanStorageRow: 3 new columns + upsert DO UPDATE SET clause - IngestionStorageMapper: map projection -> row - ComputeCost: additive per-class pricing, cache/reasoning rates fall back to input/output rate when a model omits them Token classes are disjoint (Anthropic/OpenAI report them separately) so costs add. Collector build 0W/0E; VerifyCollectorSemanticAttributeCatalog green. Also recorded scoping verdicts in yurekami-harvest.md: harvest #1/#3/#4 are REF-ONLY (already handled in qyl) -- no dead code written. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Problem
Das qyl-Projekt hatte zwei systematische Build-Probleme:
1. ❌ NU1506: Duplicate PackageVersion Errors
Ursache:
Directory.Packages.propsdefinierte Pakete mitUpdate="...", die bereits vom ANcpLua.NET.Sdk bereitgestellt wurden → Kollision beim NuGet restore.2.⚠️ Veraltete SDK-Versionen
3. 📦 Keine Dependabot-Konfiguration
Lösung
✅ 1. Dependabot konfiguriert (
.github/dependabot.yml)ANcpLua.NET.Sdk*Pakete zusammen✅ 2. SDK auf 1.6.29 aktualisiert (
global.json)✅ 3. Package-Duplikate entfernt (
Directory.Packages.props)Entfernt:
<PackageVersion Update="ANcpLua.Analyzers" Version="1.10.2"/><PackageVersion Update="Microsoft.CodeAnalysis.BannedApiAnalyzers" Version="3.3.4" /><PackageVersion Update="JonSkeet.RoslynAnalyzers" Version="1.0.0-beta.6"/><PackageVersion Include="Microsoft.Sbom.Targets" Version="4.1.5"/>Hinzugefügt:
Behalten:
ANcpLua.Roslyn.Utilities*- projektspezifische VersionenErgebnis
✅ NU1506 Duplikat-Fehler behoben
✅ SDK auf neueste Version (1.6.29)
✅ Dependabot verhindert zukünftige Versionskonflikte
✅ Build sollte jetzt mit PublishAot=true erfolgreich sein
Testing
Nach Merge dieses PRs:
dotnet restoresollte keine NU1506-Fehler mehr zeigendotnet buildsollte erfolgreich durchlaufenÄnderungen
.github/dependabot.yml(66 Zeilen)global.json(SDK 1.6.26 → 1.6.29)Directory.Packages.props(4 doppelte Einträge entfernt, Dokumentation hinzugefügt)🤖 Generated with Claude Sonnet 4.5
Summary by CodeRabbit
Chores
Documentation
✏️ Tip: You can customize this high-level summary in your review settings.