fix: ensure newline at end of file in multiple source files#70
Conversation
Dependency ReviewThe following issues were found:
License Issues.github/workflows/docs.yml
.github/workflows/release.yml
Tests/CaeriusNet.Analyzer.Tests/CaeriusNet.Analyzer.Tests.csproj
Tests/CaeriusNet.Generator.Tests/CaeriusNet.Generator.Tests.csproj
Tests/CaeriusNet.IntegrationTests/CaeriusNet.IntegrationTests.csproj
Tests/CaeriusNet.Tests/CaeriusNet.Tests.csproj
OpenSSF Scorecard
Scanned Files
|
… IDisposable' Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This PR goes far beyond “ensure newline at end of file”: it introduces repo-wide formatting fixes, new packaging/validation tooling, source-generator/analyzer behavior changes, and a substantial documentation/CI update set.
Changes:
- Add NuGet package validation tooling (PowerShell script + CI/release workflow wiring) and adjust packaging to include analyzer/generator DLLs.
- Update core runtime behavior around parameter handling/transactions (parameter cloning/normalization, TVP re-enumeration, transaction completion-slot gating) with expanded tests.
- Expand and harden generator/analyzer rules (string-literal escaping, internal type emission, skip nested/generic + new CAERIUS006), plus major docs refresh (VitePress).
Reviewed changes
Copilot reviewed 78 out of 227 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| global.json | Pins .NET SDK version/roll-forward behavior. |
| eng/ValidatePackage.ps1 | Adds package content validation + consumer smoke test script. |
| Tests/CaeriusNet.Tests/Transactions/CaeriusNetTransactionTests.cs | Adds deterministic tests for commit/rollback when a command is in-flight. |
| Tests/CaeriusNet.Tests/Telemetry/CaeriusTelemetryOptionsTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Telemetry/CaeriusDiagnosticsMetricsTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Telemetry/CaeriusActivityExtensionsTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Mappers/StoredProcedureParametersTests.cs | Adds constructor guard tests and parameter-cloning/TVP behavior tests. |
| Tests/CaeriusNet.Tests/Logging/LoggerProviderTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Logging/LogMessagesSmokeTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Helpers/TestTvpItem.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Helpers/SqlExceptionFactory.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Helpers/EmptyCollectionsTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Helpers/CacheHelperTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/GlobalUsings.cs | Formatting/newline normalization. |
| Tests/CaeriusNet.Tests/Factories/CaeriusNetDbContextTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Exceptions/CaeriusNetSqlExceptionTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/CaeriusNet.Tests.csproj | Bumps Microsoft.NET.Test.Sdk. |
| Tests/CaeriusNet.Tests/Caches/RedisCacheManagerTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Caches/InMemoryCacheManagerTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Caches/FrozenCacheStateCollection.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Caches/FrozenCacheManagerTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Caches/CaeriusNetCacheInvalidationTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Builders/StoredProcedureParametersBuilderTests.cs | Updates null handling expectations + adds negative capacity/timeout tests. |
| Tests/CaeriusNet.Tests/Builders/StoredProcedureParametersBuilderTelemetryTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Tests/Builders/CaeriusNetBuilderTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.IntegrationTests/Tests/TvpRoundtripTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.IntegrationTests/Tests/TransactionTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.IntegrationTests/Tests/StoredProcedureTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.IntegrationTests/Tests/ReadCommandsTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.IntegrationTests/Tests/MultiResultSetTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.IntegrationTests/Tests/ExceptionHandlingTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.IntegrationTests/Tests/CacheIntegrationTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.IntegrationTests/Models/WidgetDto.cs | Formatting/newline normalization. |
| Tests/CaeriusNet.IntegrationTests/GlobalUsings.cs | Formatting/newline normalization. |
| Tests/CaeriusNet.IntegrationTests/Fixtures/SqlServerFixture.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.IntegrationTests/CaeriusNet.IntegrationTests.csproj | Bumps Microsoft.NET.Test.Sdk. |
| Tests/CaeriusNet.Generator.Tests/Utilities/SourceGeneratorTestHelper.cs | Adds helper to run generator and return updated compilation; adds SqlClient reference. |
| Tests/CaeriusNet.Generator.Tests/Tvp/TvpSourceGeneratorTests.cs | Adds tests for escaping, null-guard emission, internal types, and skipping nested/generic. |
| Tests/CaeriusNet.Generator.Tests/Helpers/TypeDetectorTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Generator.Tests/Helpers/SqlMetaDataExpressionBuilderTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Generator.Tests/Helpers/NamespaceHelperTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Generator.Tests/GlobalUsings.cs | Formatting/newline normalization. |
| Tests/CaeriusNet.Generator.Tests/Dto/DtoSourceGeneratorTests.cs | Updates TimeOnly mapping expectation; adds numeric-cast/internal/skip nested+generic tests. |
| Tests/CaeriusNet.Generator.Tests/Diagnostics/DiagnosticTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Generator.Tests/CaeriusNet.Generator.Tests.csproj | Bumps Microsoft.NET.Test.Sdk. |
| Tests/CaeriusNet.Generator.Tests/Caching/IncrementalCachingTests.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Analyzer.Tests/Utilities/AnalyzerTestHelper.cs | EOF newline/formatting adjustment. |
| Tests/CaeriusNet.Analyzer.Tests/GlobalUsings.cs | Formatting/newline normalization. |
| Tests/CaeriusNet.Analyzer.Tests/GeneratorUsageAnalyzerTests.cs | Adds CAERIUS006 tests + verifies alias attribute analysis. |
| Tests/CaeriusNet.Analyzer.Tests/CaeriusNet.Analyzer.Tests.csproj | Bumps Microsoft.NET.Test.Sdk. |
| Src/Telemetry/CaeriusTelemetryOptions.cs | EOF newline/formatting adjustment. |
| Src/Telemetry/CaeriusDiagnostics.cs | EOF newline/formatting adjustment. |
| Src/Telemetry/CaeriusActivityExtensions.cs | EOF newline/formatting adjustment. |
| Src/README.md | Updates usage examples (ResultSetCapacity, ExecuteNonQueryAsync returning int, etc.). |
| Src/Mappers/StoredProcedureParameters.cs | Adds argument guards + parameter cloning into SqlCommand collections. |
| Src/Mappers/ITvpMapper.cs | Whitespace/indent normalization. |
| Src/Mappers/ISpMapper.cs | Whitespace/indent normalization. |
| Src/Logging/LoggerProvider.cs | Whitespace/indent normalization. |
| Src/Logging/LogMessages.cs | EOF newline/formatting adjustment. |
| Src/Helpers/SqlCommandHelperTx.cs | Switches to AddParametersTo cloning; adds capacity helpers; replaces CollectionsMarshal writes with List.Add. |
| Src/Helpers/MultiResultSetHelper.cs | Replaces CollectionsMarshal list fill with List.Add; adds capacity helpers. |
| Src/Helpers/EmptyCollections.cs | Whitespace/indent normalization. |
| Src/Helpers/CacheType.cs | Whitespace/indent normalization. |
| Src/Helpers/CacheHelper.cs | Whitespace/indent normalization. |
| Src/GlobalUsings.cs | Formatting/newline normalization. |
| Src/Factories/CaeriusNetTransaction.cs | Adds completion-slot gating for commit/rollback to avoid in-flight command races. |
| Src/Factories/CaeriusNetDbContext.cs | EOF newline/formatting adjustment. |
| Src/Exceptions/CaeriusNetSqlException.cs | Formatting/newline normalization. |
| Src/Commands/Writes/WriteSqlAsyncCommands.cs | EOF newline/formatting adjustment. |
| Src/Commands/Transactions/TransactionWriteSqlAsyncCommands.cs | EOF newline/formatting adjustment. |
| Src/Commands/Transactions/TransactionReadSqlAsyncCommands.cs | EOF newline/formatting adjustment. |
| Src/Commands/Transactions/BeginTransactionAsyncCommands.cs | EOF newline/formatting adjustment. |
| Src/Commands/Reads/SimpleReadSqlAsyncCommands.cs | EOF newline/formatting adjustment. |
| Src/Commands/Reads/MultiReadOnlyCollectionReadSqlAsyncCommands.cs | EOF newline/formatting adjustment. |
| Src/Commands/Reads/MultiImmutableArrayReadSqlAsyncCommands.cs | EOF newline/formatting adjustment. |
| Src/Commands/Reads/MultiIEnumerableReadSqlAsyncCommands.cs | EOF newline/formatting adjustment. |
| Src/CaeriusNet.csproj | Packaging changes (include analyzer/generator DLLs), docfile generation, warning suppressions. |
| Src/Caches/RedisCacheManager.cs | Whitespace/indent normalization. |
| Src/Caches/InMemoryCacheManager.cs | Whitespace/indent normalization. |
| Src/Caches/FrozenCacheManager.cs | Whitespace/indent normalization. |
| Src/Caches/CaeriusNetCache.cs | EOF newline/formatting adjustment. |
| Src/Builders/StoredProcedureParametersBuilder.cs | Null→DBNull normalization, TVP re-enumerable wrapper, negative guards, signature docs tweaks. |
| Src/Builders/CaeriusNetBuilder.cs | EOF newline/formatting adjustment. |
| Src/Attributes/Tvp/GenerateTvpAttribute.cs | Whitespace/indent normalization. |
| Src/Attributes/Dto/GenerateDtoAttribute.cs | Formatting/newline normalization. |
| Src/Abstractions/IRedisCacheManager.cs | EOF newline/formatting adjustment. |
| Src/Abstractions/ICaeriusNetTransaction.cs | EOF newline/formatting adjustment. |
| Src/Abstractions/ICaeriusNetDbContext.cs | Whitespace/indent normalization. |
| Src/Abstractions/ICaeriusNetCache.cs | EOF newline/formatting adjustment. |
| SourceGenerators/Tvp/TvpSourceGenerator.cs | EOF newline/formatting adjustment. |
| SourceGenerators/Tvp/TvpExtractor.cs | Skips nested/generic; emits accessibility keyword; adds accessibility helper. |
| SourceGenerators/Tvp/TvpEmitter.cs | Escapes generated string literals; adds null-guard wrapper iterator; emits internal/public based on model. |
| SourceGenerators/Models/TvpModel.cs | Adds accessibility keyword to model. |
| SourceGenerators/Models/EquatableArray.cs | EOF newline/formatting adjustment. |
| SourceGenerators/Models/DtoModel.cs | Adds accessibility keyword to model. |
| SourceGenerators/Models/ColumnModel.cs | EOF newline/formatting adjustment. |
| SourceGenerators/Models/ColumnKind.cs | EOF newline/formatting adjustment. |
| SourceGenerators/Helpers/TypeStructureValidator.cs | Adds top-level/non-generic validation data. |
| SourceGenerators/Helpers/TypeDetector.cs | Whitespace/indent normalization. |
| SourceGenerators/Helpers/SqlMetaDataExpressionBuilder.cs | EOF newline/formatting adjustment. |
| SourceGenerators/Helpers/NamespaceHelper.cs | EOF newline/formatting adjustment. |
| SourceGenerators/Helpers/IsExternalInit.cs | Formatting/newline normalization. |
| SourceGenerators/Helpers/HintNameBuilder.cs | EOF newline/formatting adjustment. |
| SourceGenerators/Helpers/GeneratedCodeInfo.cs | Formatting/newline normalization. |
| SourceGenerators/Helpers/ColumnExtractor.cs | Formatting/newline normalization. |
| SourceGenerators/GlobalUsings.cs | Formatting/newline normalization. |
| SourceGenerators/Dto/DtoSourceGenerator.cs | EOF newline/formatting adjustment. |
| SourceGenerators/Dto/DtoExtractor.cs | Skips nested/generic; emits accessibility keyword. |
| SourceGenerators/Dto/DtoEmitter.cs | Emits internal/public, fixes TimeOnly mapping, adds explicit casts for narrow/unsigned, improves enum handling. |
| SUPPORT.md | Updates support links and diagnostics references. |
| README.md | Adds package validation docs section; clarifies Exemples naming. |
| Exemples/README.md | Adds note about historical Exemples/ directory name. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Services/UsersService.cs | EOF newline/formatting adjustment. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Repositories/UsersRepository.cs | Formatting/newline normalization. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Repositories/UsersRepository.Tvp.cs | Removes nullable fallback (?? []) now that API returns non-null. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Repositories/UsersRepository.Transactions.cs | Parameter naming changes in examples (no leading @). |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Repositories/UsersRepository.Reads.cs | Removes nullable fallback; adjusts example parameter naming. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Repositories/UsersRepository.MultiResultSets.cs | EOF newline/formatting adjustment. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Models/Tvps/UsersIntTvp.cs | Formatting/newline normalization. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Models/Tvps/UsersIntGuidTvp.cs | Formatting/newline normalization. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Models/Tvps/UsersGuidTvp.cs | Formatting/newline normalization. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Models/Dtos/UserStatsDto.cs | Formatting/newline normalization. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Models/Dtos/UserDto.cs | Formatting/newline normalization. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Models/Dtos/OrderDto.cs | Formatting/newline normalization. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/GlobalUsings.cs | Formatting/newline normalization. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Extensions/ServiceCollectionExtension.cs | EOF newline/formatting adjustment. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Bootstrap/ExampleDatabaseBootstrapper.cs | EOF newline/formatting adjustment. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Abstractions/IUsersService.cs | EOF newline/formatting adjustment. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Abstractions/IUsersRepository.cs | EOF newline/formatting adjustment. |
| Exemples/Libs/CaeriusNet.Exemples.Libs.Commons/Abstractions/DashboardSnapshot.cs | Formatting/newline normalization. |
| Exemples/Default/CaeriusNet.Exemples.Default.Console/Program.cs | EOF newline/formatting adjustment. |
| Exemples/Default/CaeriusNet.Exemples.Default.Console/GlobalUsings.cs | Formatting/newline normalization. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.ServiceDefaults/GlobalUsings.cs | Formatting/newline normalization. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.ServiceDefaults/Extensions.cs | EOF newline/formatting adjustment. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.Console/Program.cs | Formatting/newline normalization. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.Console/GlobalUsings.cs | Formatting/newline normalization. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.Console/DemoWorker.cs | EOF newline/formatting adjustment. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.Console/DemoSections/TvpReadDemo.cs | EOF newline/formatting adjustment. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.Console/DemoSections/TransactionDemo.cs | EOF newline/formatting adjustment. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.Console/DemoSections/ReadDemo.cs | EOF newline/formatting adjustment. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.Console/DemoSections/MultiResultSetDemo.cs | EOF newline/formatting adjustment. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.AppHost/GlobalUsings.cs | Formatting/newline normalization. |
| Exemples/Aspire/CaeriusNet.Exemples.Aspire.AppHost/AppHost.cs | Formatting/newline normalization. |
| Documentations/docs/quickstart/what-is-caeriusnet.md | Refines positioning/scope and updates performance/feature wording. |
| Documentations/docs/quickstart/getting-started.md | Adds scope/tips; updates examples and command namespaces. |
| Documentations/docs/index.md | Major VitePress home refresh (scope, map, links). |
| Documentations/docs/examples/tvp.md | Updates capacity naming + removes nullable fallbacks; updates parameter naming examples. |
| Documentations/docs/examples/transactions.md | Updates parameter naming examples (no @). |
| Documentations/docs/examples/stored-procedures.md | Updates capacity naming + removes nullable fallback; updates parameter naming examples. |
| Documentations/docs/examples/multi-result-sets.md | Updates capacity naming. |
| Documentations/docs/examples/index.md | Clarifies example conventions and parameter naming. |
| Documentations/docs/documentation/usage.md | Removes nullable fallback for QueryAsIEnumerableAsync. |
| Documentations/docs/documentation/tvp.md | Updates capacity naming. |
| Documentations/docs/documentation/reading-data.md | Updates capacity naming + removes nullable fallback. |
| Documentations/docs/documentation/diagnostics.md | Moves diagnostics links to VitePress routing; updates guide copy. |
| Documentations/docs/documentation/aspire.md | Removes nullable fallback. |
| Documentations/docs/documentation/api.md | Updates API reference (builder args, namespaces, telemetry options, Redis cache). |
| Documentations/docs/documentation/advanced-usage.md | Updates capacity naming + removes nullable fallback. |
| Documentations/docs/diagnostics/index.md | Adds diagnostics landing page (VitePress). |
| Documentations/docs/diagnostics/CAERIUS001.md | Adds VitePress diagnostic rule page. |
| Documentations/docs/diagnostics/CAERIUS002.md | Adds VitePress diagnostic rule page. |
| Documentations/docs/diagnostics/CAERIUS003.md | Adds VitePress diagnostic rule page. |
| Documentations/docs/diagnostics/CAERIUS004.md | Adds VitePress diagnostic rule page. |
| Documentations/docs/diagnostics/CAERIUS005.md | Adds VitePress diagnostic rule page. |
| Documentations/docs/benchmarks/sql-server.md | Reframes benchmark interpretation language; adds environment caveats. |
| Documentations/docs/benchmarks/performance.md | Restructures benchmark index page. |
| Documentations/docs/benchmarks/index.md | Clarifies methodology and result interpretation language. |
| Documentations/docs/benchmarks/in-memory.md | Updates generator naming + benchmark interpretation wording. |
| Documentations/docs/.vitepress/config.mts | Updates nav/sidebar (diagnostics section, quickstart link changes). |
| CONTRIBUTING.md | Updates repo structure notes and adds docs/package validation commands. |
| CHANGELOG.md | Adds initial changelog with VitePress-related notes. |
| Benchmark/Workshops/Benchs/Tvp/TvpVsDataTableBench.cs | Disposes DataTable clones; makes benchmark class sealed + IDisposable. |
| Benchmark/Workshops/Benchs/Tvp/TvpSerializationBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/Tvp/TvpColumnScalingBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/SqlServer/TvpFullRoundtripBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/SqlServer/SqlBenchmarkGlobalSetup.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/SqlServer/SpOutputParameterBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/SqlServer/SpExecutionBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/SqlServer/MultiResultSetBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/SqlServer/ConnectionPoolBench.cs | Adds IDisposable + ensures persistent connection is cleared/disposed deterministically. |
| Benchmark/Workshops/Benchs/SqlServer/BatchedVsSingleBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/ReadCollections/ReadReadOnlyCollectionToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/ReadCollections/ReadListToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/ReadCollections/ReadImmutableArrayToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/ReadCollections/ReadEnumerableToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/Parameters/SpParameterBuilderBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/Parameters/AddTvpParameterBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/Mapping/WideRowDtoMappingBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/Mapping/NullableColumnMappingBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/Mapping/DtoMappingBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/ListCapacity/ListWithoutCapacityToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/ListCapacity/ListWithLessCapacityThanNeededToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/ListCapacity/ListWithCapacityWithOverextendToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/ListCapacity/ListWithCapacityToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/CreateCollections/CreateReadOnlyCollectionToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/CreateCollections/CreateListToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/CreateCollections/CreateImmutableArrayToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/CreateCollections/CreateEnumerableToBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/Benchs/Cache/InMemoryCacheBench.cs | Adds IDisposable and unifies cleanup via Dispose. |
| Benchmark/Workshops/Benchs/Cache/FrozenCacheBench.cs | EOF newline/formatting adjustment. |
| Benchmark/Workshops/BenchmarkConfig.cs | EOF newline/formatting adjustment. |
| Benchmark/Usings.cs | Formatting/newline normalization. |
| Benchmark/RunningBenchmarks.cs | EOF newline/formatting adjustment. |
| Benchmark/Program.cs | EOF newline/formatting adjustment. |
| Benchmark/Data/Simple/SimpleDto.cs | EOF newline/formatting adjustment. |
| Benchmark/Data/Generated/WideRowDto.cs | Formatting/newline normalization. |
| Benchmark/Data/Generated/NullableRowDto.cs | Formatting/newline normalization. |
| Benchmark/Data/Generated/BenchmarkTvpItem5Col.cs | Formatting/newline normalization. |
| Benchmark/Data/Generated/BenchmarkTvpItem10Col.cs | Formatting/newline normalization. |
| Benchmark/Data/Generated/BenchmarkTvpItem.cs | Formatting/newline normalization. |
| Benchmark/Data/Generated/BenchmarkItemDto.cs | Formatting/newline normalization. |
| Analyzer/Helpers/TypeStructureValidator.cs | Adds top-level/non-generic validation info for CAERIUS006. |
| Analyzer/Helpers/SqlTypeDetector.cs | EOF newline/formatting adjustment. |
| Analyzer/GlobalUsings.cs | Formatting/newline normalization. |
| Analyzer/GeneratorUsageAnalyzer.cs | Adds CAERIUS006 reporting and supports aliased attribute usage. |
| Analyzer/Diagnostics/DiagnosticDescriptors.cs | Adds CAERIUS006 descriptor. |
| Analyzer/AnalyzerReleases.Unshipped.md | Tracks CAERIUS006 in analyzer release notes. |
| .github/workflows/security.yml | Adds permissions + concurrency controls. |
| .github/workflows/release.yml | Adds docs build, integration tests, package validation, and release metadata validation. |
| .github/workflows/nuget-dotnet.yml | Adds concurrency; adjusts commit message (removes [skip ci]). |
| .github/workflows/github-pages-deploy.yml | Improves npm caching + uses npm ci when lockfile exists. |
| .github/workflows/docs.yml | New workflow to build docs on PR/push when docs change. |
| .github/workflows/codeql.yml | Adds concurrency controls. |
| .github/workflows/ci.yml | Adds package validation step; adjusts test filter. |
| .github/PULL_REQUEST_TEMPLATE.md | Adds explicit package/docs validation checklist items. |
| .editorconfig | Introduces repo-wide editor settings including insert_final_newline. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| public StoredProcedureParametersBuilder AddTvpParameter<T>(string parameter, IEnumerable<T> items) | ||
| where T : class, ITvpMapper<T> | ||
| { | ||
| ArgumentException.ThrowIfNullOrEmpty(parameter); | ||
| var tvpList = items as IList<T> ?? items.ToList(); | ||
| if (tvpList.Count == 0) | ||
| var tvpItems = items as T[] ?? items.ToArray(); | ||
| if (tvpItems.Length == 0) | ||
| throw new ArgumentException("No items found in the collection to map to a Table-Valued Parameter."); | ||
|
|
There was a problem hiding this comment.
AddTvpParameter materializes items via items as T[] ?? items.ToArray() without a direct null-guard, so a null items will throw an ArgumentNullException with ParamName source from LINQ rather than items. Add ArgumentNullException.ThrowIfNull(items) before the ToArray to make the exception deterministic and API-friendly.
| { | ||
| "sdk": { | ||
| "version": "10.0.203", |
There was a problem hiding this comment.
PR title/description indicate only ensuring final newlines, but this PR introduces substantial behavioral, generator/analyzer, packaging, CI, and documentation changes. Please update the PR title and/or description to accurately reflect the scope so reviewers know what to focus on and release notes/changelog can be assessed correctly.
| DiagnosticSeverity.Error, | ||
| true, | ||
| "CaeriusNet generators emit companion partial declarations and currently support only non-generic top-level types.", | ||
| HelpLinkBase + "CAERIUS006.md"); |
There was a problem hiding this comment.
CAERIUS006 is added, but its HelpLink points to Documentations/diagnostics/CAERIUS006.md, which is not present alongside CAERIUS001–CAERIUS005. Add the missing CAERIUS006 documentation page (or adjust the HelpLinkBase/filename) so IDE links don’t 404.
| HelpLinkBase + "CAERIUS006.md"); | |
| null); |
| /// <summary> | ||
| /// Reads a single result set into a List using CollectionsMarshal for zero-copy access. | ||
| /// </summary> | ||
| /// <typeparam name="T">The type to map the result set rows to</typeparam> | ||
| /// <param name="reader">The SqlDataReader to read from</param> | ||
| /// <param name="capacity">Initial capacity for the List</param> | ||
| /// <param name="cancellationToken">Cancellation token</param> | ||
| /// <returns>A List containing the mapped rows</returns> | ||
| /// <remarks> | ||
| /// Uses CollectionsMarshal for optimized list access without additional allocations | ||
| /// </remarks> | ||
| [MethodImpl(MethodImplOptions.AggressiveOptimization)] | ||
| internal static async ValueTask<List<T>> ReadResultSetAsync<T>( | ||
| SqlDataReader reader, | ||
| int capacity, |
There was a problem hiding this comment.
The XML docs here claim the helper reads result sets using CollectionsMarshal for zero-copy access, but the implementation now uses list.Add(...) (no CollectionsMarshal.SetCount/AsSpan). Please update the documentation (or restore the claimed implementation) to keep comments accurate.
|
@copilot apply changes based on the comments in this thread |
…AERIUS006.md Agent-Logs-Url: https://github.com/CaeriusNET/CaeriusNet/sessions/51be8d33-8349-4e29-9162-e7ee218b3392 Co-authored-by: AriusII <35581726+AriusII@users.noreply.github.com>
Applied all four review changes in commit b6bd315:
|
…properties and methods
SummarySummary
CoverageCaeriusNet - 30.1%
|
Summary
Motivation
Type of change
Checklist
CONTRIBUTING.md.dotnet build CaeriusNet.slnx -c Release -p:TreatWarningsAsErrors=truesucceeds locally.dotnet test CaeriusNet.slnx -c Release --filter "FullyQualifiedName!~IntegrationTests"is green.CHANGELOG.mdunder[Unreleased]if user-visible.Public-API impact
Benchmark / performance notes
Screenshots / logs (optional)