Skip to content

Diagnostic rules

CaeriusNet analyzers validate [GenerateDto], [GenerateTvp], and AutoContracts manifest inputs at compile time. Diagnostics are emitted by the analyzer included with the CaeriusNet package and appear in IDE builds and dotnet build.

Use these pages as the rule reference for generated DTO, TVP mapper, and AutoContracts manifest issues.

IDSeveritySummary
CAERIUS001ErrorType must be sealed
CAERIUS002ErrorType must be partial
CAERIUS003ErrorType must declare a primary constructor
CAERIUS004ErrorTvpName must not be empty
CAERIUS005ErrorCLR type has no faithful SQL Server mapping
CAERIUS006ErrorGenerator target shape is not supported
CAERIUS007ErrorManual TVP column metadata is invalid
CAERIUS008ErrorDTO source emission failed without a generator exception
CAERIUS200ErrorAutoContracts manifest is missing
CAERIUS201ErrorStored procedure could not be found
CAERIUS202ErrorReferenced TVP type is missing
CAERIUS203ErrorTVP SQL type is not supported
CAERIUS204ErrorFirst projection cannot be determined
CAERIUS205WarningStored procedure has no result set
CAERIUS206ErrorParameter direction is not supported
CAERIUS207ErrorSQL type cannot be mapped
CAERIUS208WarningNullable result column
CAERIUS209ErrorContract hash differs during Verify
CAERIUS210WarningProcedure may be incompatible with generated contracts

Build policy

Keep error diagnostics fixed in source. CAERIUS005 has no sql_variant fallback, so suppressing it cannot enable generation. Treat warning suppressions as design decisions and prefer documenting them near the affected contract.

See also the higher-level Compiler Diagnostics guide for suppression and severity configuration.

Released under the MIT License.