Bump NJsonSchema from 11.3.2 to 11.6.1#10
Merged
github-actions[bot] merged 1 commit intoMay 1, 2026
Conversation
--- updated-dependencies: - dependency-name: NJsonSchema dependency-version: 11.6.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
5c739fd to
671da3e
Compare
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.
Updated NJsonSchema from 11.3.2 to 11.6.1.
Release notes
Sourced from NJsonSchema's releases.
11.6.1
Corrections to v11.6.0
v11.6.0 added support for the C# 11
requiredkeyword and[JsonRequired]in schema generation (#1908), but folded them into the same bucket as DataAnnotations[Required]— which conflated three distinct concepts:requiredarray):requiredkeyword,[JsonRequired],[Required],[DataMember(IsRequired=true)], NewtonsoftRequired.Always/AllowNull[Required]only (plus NewtonsoftRequired.Always/DisallowNullfor runtime correctness)MinLength=1on strings):[Required]only (unlessAllowEmptyStrings=true)v11.6.1 (#1919) restores the correct separation. The
requiredkeyword and[JsonRequired]are now presence-only markers — they add the property to the schema'srequiredarray without suppressing nullability or addingMinLength=1.Behavioral deltas vs v11.6.0 (all restoring correctness)
required string?nullable: false,MinLength: 1❌nullable: true, noMinLength✅required stringMinLength: 1❌MinLength✅[JsonRequired] string?nullable: false,MinLength: 1❌nullable: true, noMinLength✅[JsonRequired] stringMinLength: 1❌MinLength✅[Required],[JsonProperty(Required=*)], and[DataMember(IsRequired=true)]semantics are unchanged across v11.5.x / v11.6.0 / v11.6.1.Downstream impact
The v11.6.0 regression surfaced in NSwag as NSwag#5359: TypeScript clients generated from
required T?DTO properties silently lost their| null, removing null-safety for fields the server can legitimately return as null. v11.6.1 fixes this. A matching NSwag release is required to pick up the fix.What's Changed
New Contributors
Full Changelog: RicoSuter/NJsonSchema@v11.6.0...v11.6.1
11.6.0
Potentially breaking changes
requiredkeyword now recognized as required: Properties using the C# 11requiredkeyword (RequiredMemberAttribute/JsonRequiredAttribute) are now correctly treated as required in schema generation and code output. Previously these were incorrectly treated as optional (Required.Default). This changes generated code: such properties now getRequired.Always,[Required]attribute, and therequiredmodifier whenUseRequiredKeywordis enabled. (#1908)JsonStringEnumMemberNameandEnumMemberattributes are now emitted for enum members when using System.Text.Json, for compatibility with NSwag's reflection-based URL parameter serialization. (#1905)$schemaversion preserved inToJson()instead of forcing draft-04. If you relied on the output always being draft-04, this may affect you. (#1881)patternPropertiesvalidation now correctly applies to all matching properties, not just the first. (#1898)DateTime,DateTimeOffset,DateOnly,TimeOnlyproperties. (#1900)What's Changed
+in JSON reference paths being decoded as space by @Copilot in Fix+in JSON reference paths being decoded as space RicoSuter/NJsonSchema#1880-1generating invalid C# identifier instead ofMinus1by @Copilot in Fix property named-1generating invalid C# identifier instead ofMinus1RicoSuter/NJsonSchema#1882New Contributors
+in JSON reference paths being decoded as space RicoSuter/NJsonSchema#1880Full Changelog: RicoSuter/NJsonSchema@v11.5.2...v11.6.0
11.5.2
What's Changed
JsonStringEnumConverter<T>detection and test it by @wellWINeo in Add support forJsonStringEnumConverter<T>detection and test it RicoSuter/NJsonSchema#1868New Contributors
JsonStringEnumConverter<T>detection and test it RicoSuter/NJsonSchema#1868Full Changelog: RicoSuter/NJsonSchema@v11.5.1...v11.5.2
11.5.1
What's Changed
New Contributors
Full Changelog: RicoSuter/NJsonSchema@v11.5.0...v11.5.1
11.5.0
What's Changed
Breaking changes:
Others:
Full Changelog: RicoSuter/NJsonSchema@v11.4.0...v11.5.0
11.4.0
What's Changed
JsonReferenceResolverby @lahma in Cache NJsonSchema properties in JsonReferenceResolver RicoSuter/NJsonSchema#1817JsonSchemaconstruction for object having boolean required by @lahma in Avoid trying JsonSchema construction for object having boolean required RicoSuter/NJsonSchema#1818AsyncJsonReferenceVisitorBase.Visitby @lahma in Optimize AsyncJsonReferenceVisitorBase.Visit RicoSuter/NJsonSchema#1819FluidParserconstruction by @lahma in Allow customizing FluidParser construction RicoSuter/NJsonSchema#1822tscby @lahma in Add support for testing whether TS code compiles with tsc RicoSuter/NJsonSchema#1824ApplyRangeAttributefailing when min/max is specified as string by @sindrekroknes in fix ApplyRangeAttribute failing when min/max is specified as string RicoSuter/NJsonSchema#1831templateFolderby @Georgy-Losenkov in Add ability to overwrite templates multiple times using templateFolder RicoSuter/NJsonSchema#1835as TYPEinstead cast with<TYPE>by @lahma in Convert to using TS "as TYPE" instead cast with <TYPE> RicoSuter/NJsonSchema#1837ValueStringBuilderinConvertDashesToCamelCaseby @lahma in Use ValueStringBuilder in ConvertDashesToCamelCase RicoSuter/NJsonSchema#1844JTokens with typeUriby @ertrumbl in Fixed validation of JTokens with type Uri RicoSuter/NJsonSchema#1403x-enumNamesvalue by @lekhmanrus in Support description for each x-enumNames value RicoSuter/NJsonSchema#1789New Contributors
Full Changelog: RicoSuter/NJsonSchema@v11.3.2...v11.4.0
Commits viewable in compare view.