Repository navigation
Spdx.Expressions 1.0.0 — Stable API, Catalogue Loading and AST Traversal
The first stable release of Spdx.Expressions: a standalone .NET 10 library for parsing, inspecting, validating and formatting SPDX license expressions, with immutable source evidence and no runtime NuGet dependencies.
New since 0.1.0
- External catalogues: load paired SPDX licence and exception catalogues from UTF-8 memory or streams using
SpdxLicenseRegistry.Load, with resource limits, structured diagnostics, cancellation and exact-byte SHA-256 identities. Caller-owned streams remain open. - AST traversal: inspect original nodes through lazy
EnumerateNodesor typedSpdxExpressionWalkercallbacks, preserving source order, explicit groups, repeated occurrences and UTF-16 spans. - Canonical identifier casing: use
FormatCanonicalCasing(expression, registry)to apply the selected catalogue’s spelling to known identifiers while preserving references, unknown identifiers, grouping and operand order.
Fixes
- Closed an immutability gap that allowed backing arrays of registry, AST and diagnostic collections to be modified through
ICollection.SyncRoot.
Stable contracts
- Established a 1.x compatibility policy covering public APIs, protected walker hooks, defaults, diagnostics and catalogue evolution.
- Preserved existing
Parse,Validateand ordinaryFormatcall patterns. Ordinary formatting continues to preserve identifier spelling. - Retained the fixed SPDX-2.3.1 expression profile and embedded SPDX License List 3.29.0.
- Catalogue selection remains explicit and offline. Patch releases retain embedded catalogue bytes; minor releases may introduce documented catalogue updates.
- Updated API documentation and examples to identify functionality available starting with 1.0.0.
Reference resolution and legal-policy decisions remain outside the library’s scope.
Verification
Release preparation passed:
- 815 tests in each of Debug and Release.
- 16 actual-package scenarios and 16 independently compiled examples.
- 66 existing consumer compatibility tests against the actual 1.0.0 package.
- Package contents, documentation and release-script checks.
Full changelog: v0.1.0...v1.0.0