Repository navigation
Releases: moonrockz/smithy
Release list
v0.6.0
Install:
mise use github:moonrockz/smithy@0.6.0moon add moonrockz/smithy-syntax@0.6.0
Wasm files:
- Both wasm files export
memoryand_startand need a host supplying the MoonBit__moonbit_fs_unstableimports and WASIfd_write,path_openandfd_close. JSONL file output uses a working-directory preopen at descriptor 3; the pinnedmoonrunprovides these imports and bounds file output to that directory. smithy.wasmalso imports WASIfd_readfor stdin andproc_exitfor exit status.smithy-gc.wasmadditionally needs WebAssembly GC andspectest.print_char.wasmtimealone cannot instantiate either file because it lacks the MoonBit host imports.
This release adds JSON-RPC support. smithy validate rpc checks requests, responses, batches and whole transcripts against a Smithy model, smithy validate value checks JSON and native Ion values, and the OpenRPC transform exports Smithy JSON-RPC services. Model validation time is now linear in the shape count: a model of 4,000 shapes validates in less than a second, not in minutes. The new project site has docs, examples and an in-browser playground that validates, transforms and checks transcripts with no server. Two changes break existing use: replace smithy validate-value with smithy validate value, and add kind to code that builds a SourceLocation with a struct literal, or use SourceLocation::new.
⚠️ Breaking changes
- (validation) Use
smithy validate valueinstead ofsmithy validate-value. Model inputs and options follow the nested subcommand. No legacy alias is provided. (#44) - (cli)
SourceLocationhas a new fieldkind : SourceKind. Code that builds aSourceLocationwith a struct literal must addkind, or useSourceLocation::new(file, path~, span?, kind~ = User). Code that only reads a location needs no change. (#57)
🚀 Features
- (validation) Validate JSON-RPC requests (#42) by @DamianReeves
- (validation) [breaking] Validate JSON-RPC responses (#44) by @DamianReeves
- (openrpc) Export Smithy JSON-RPC services (#45) by @DamianReeves
- Add HTTP protocol test suites (#46) by @DamianReeves
- (validation) Validate JSON-RPC batches (#47) by @DamianReeves
- (validation) Validate native Ion values (#48) by @DamianReeves
- (validation) Validate JSON-RPC transcripts (#49) by @DamianReeves
- (validation) Finish JSON-RPC transcript follow-ups (#50) by @DamianReeves
- (openrpc) Build documents with published moonrockz/openrpc 0.2.0 (#55) by @DamianReeves
- (site) Add the project site with docs and examples (#56) by @DamianReeves
- (site) Add the in-browser playground (#60) by @DamianReeves
- (site) Show playground progress, group the Validate list and fold the controls (#62) by @DamianReeves
🐛 Bug fixes
- (validation) Support recorded RFC 3339 leap seconds (#43) by @DamianReeves
- (validation) Make unreadable transcript input and refused entries consistent (#52) by @DamianReeves
- (cli) Report an unreadable stdin on js instead of crashing (#53) by @DamianReeves
- (cli) [breaking] Resolve the smithy.rpc traits in every model command (#57) by @DamianReeves
- (site) Link the other version to a page it has (#59) by @DamianReeves
⚡ Performance
- (smithy) Make model validation linear in the shape count (#61) by @DamianReeves
🏗️ Build and CI
- Smoke on evidence and stop release dry runs on feature pull requests (#51) by @DamianReeves
- File one GitHub issue per smoke breach (#54) by @DamianReeves
- (site) Build deployable site runs one at a time (#58) by @DamianReeves
Full changelog: v0.5.0...v0.6.0
v0.5.0
Install:
mise use github:moonrockz/smithy@0.5.0moon add moonrockz/smithy-syntax@0.5.0
Wasm files:
- Both wasm files export
memoryand_startand need a host supplying the MoonBit__moonbit_fs_unstableimports and WASIfd_write,path_openandfd_close. JSONL file output uses a working-directory preopen at descriptor 3; the pinnedmoonrunprovides these imports and bounds file output to that directory. smithy.wasmalso imports WASIfd_readfor stdin andproc_exitfor exit status.smithy-gc.wasmadditionally needs WebAssembly GC andspectest.print_char.wasmtimealone cannot instantiate either file because it lacks the MoonBit host imports.
Validate JSON files against Smithy shapes with smithy validate-value or reuse prepared contracts from the new moonrockz/smithy-validation package. Structured findings identify exact instance paths, preserve numeric precision and enforce bounded traversal and pattern work across supported targets. This release also adds OpenAPI export and model compatibility diffs with JSONL event output. The shared JSON-RPC/OpenRPC design is documented for the next protocol-validation slices; date-time value validation currently excludes leap-second notation.
🚀 Features
- (openapi) Convert Smithy services to OpenAPI (#36) by @DamianReeves
- (diff) Compare Smithy model compatibility (#37) by @DamianReeves
- (validation) Validate JSON values through the library and CLI (#38) by @DamianReeves
- (diff) Add JSONL event output (#39) by @DamianReeves
🐛 Bug fixes
- (release) Update every package pin in standalone consumers (#41) by @DamianReeves
Full changelog: v0.4.0...v0.5.0
v0.4.0
Install:
mise use github:moonrockz/smithy@0.4.0moon add moonrockz/smithy-syntax@0.4.0
Wasm files:
smithy.wasmneeds a host that supplies the__moonbit_fs_unstableimports andwasi_snapshot_preview1.fd_write.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….smithy-gc.wasmneeds a host with WebAssembly GC that supplies the__moonbit_fs_unstableimports andspectest.print_char.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….
The new moonrockz/artifact-resources package loads selected resource trees from directories, ZIP/JAR, tar/gzip and npm archives, with validated paths, logical aliases and structured provenance. Smithy build sources, global imports and projection imports can now acquire public archive URLs, pinned GitHub release assets, exact npm versions and pinned Maven JARs with integrity verification, shared caching and explicit offline builds. Private repositories accept supplied Bearer or Basic credentials bound to exact origins through environment references; redirects strip authorization across origins and authenticated cache entries are isolated. Existing JSON string inputs and JAR manifest discovery remain compatible. Library callers must migrate resource metadata to domain types, wrap path inputs with BuildInput::from_path, initialize the added cache/offline/credential configuration fields, handle the new input/provenance/diagnostic variants, and update custom HTTP transports to receive HttpRequest as detailed below.
⚠️ Breaking changes
- (resources) Resource metadata uses validated domain types;
BuildConfig.sources,BuildConfig.importsandProjectionConfig.importscontainBuildInputvalues. UseBuildInput::from_pathfor legacy library inputs. JSON string configuration remains compatible. API migration and selection rules are documented. (#28) - (resources) BuildInput adds Remote(PublicArchive, Selection), and with_location can raise BuildError for invalid remote replacement URLs. Exhaustive ResourceCode and ProvenanceStep matches need acquisition cases. (#30)
- (resources) Direct BuildConfig constructors must initialize cache_directory: CacheDirectory and offline. Parsed configuration supplies defaults. Exhaustive Location matches must handle FilesystemDirectory. (#31)
- (resources) Exhaustive matches must handle BuildInput::GitHub, GitHubRequestStep/GitHubStep provenance, and MissingRelease, AmbiguousAsset and RateLimited resource codes. (#32)
- (resources) Exhaustive
BuildInputmatches must handleNpm(NpmArchive, Selection)andMaven(MavenArchive, Selection?);Noneselects Maven manifest discovery. ExhaustiveProvenanceStepmatches must handleNpmRequestStep,NpmStep,MavenRequestStepandMavenStep;ResourceCodematches must handleMissingPackageVersion,MissingArtifactandUnsupportedIntegrity. Repository inputlocation()values are registry/repository bases andwith_location()validates replacements. (#33) - (resources)
HttpTransportreceivesHttpRequestinstead ofHttpUrl. Userequest.urlinside callbacks andHttpRequest::anonymous(url)for public host calls. DirectBuildConfigconstructors must initializecredentials: Array[CredentialBinding]; use[]for anonymous acquisition. Parsed configuration supplies the default. (#34)
🚀 Features
- Add reusable local artifact resources (#27) by @DamianReeves
- (resources) [breaking] Select local resource trees (#28) by @DamianReeves
- (resources) Load local tar and npm archives (#29) by @DamianReeves
- (resources) [breaking] Load verified public archives (#30) by @DamianReeves
- (resources) [breaking] Cache artifacts for offline builds (#31) by @DamianReeves
- (resources) [breaking] Load pinned GitHub release assets (#32) by @DamianReeves
- (resources) [breaking] Load npm and Maven artifacts (#33) by @DamianReeves
- (resources) [breaking] Add repository credentials (#34) by @DamianReeves
Full changelog: v0.3.0...v0.4.0
v0.3.0
Install:
mise use github:moonrockz/smithy@0.3.0moon add moonrockz/smithy-syntax@0.3.0
Wasm files:
smithy.wasmneeds a host that supplies the__moonbit_fs_unstableimports andwasi_snapshot_preview1.fd_write.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….smithy-gc.wasmneeds a host with WebAssembly GC that supplies the__moonbit_fs_unstableimports andspectest.print_char.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….
Smithy now converts assembled models to JSON Schema through the new moonrockz/smithy-jsonschema package and the jsonSchema build plugin. The new moonrockz/smithy-build package and smithy build and smithy clean commands support projections, all 28 built-in transforms, local JAR imports and environment substitutions. smithy select evaluates selectors, and validation now runs configured and default validators with reference event IDs, severities, shape IDs and suppressions. Build outputs require a dedicated directory separate from sources and imports, with an ownership marker protecting existing files. Code that constructs Shape, ModelDiagnostic or LoadResult records directly must supply the added provenance, event_id and validation_findings fields respectively; loader callers need no record changes.
🚀 Features
- Add JSON Schema conversion and build toolchain (#25) by @DamianReeves
Full changelog: v0.2.0...v0.3.0
v0.2.0
Install:
mise use github:moonrockz/smithy@0.2.0moon add moonrockz/smithy-syntax@0.2.0
Wasm files:
smithy.wasmneeds a host that supplies the__moonbit_fs_unstableimports andwasi_snapshot_preview1.fd_write.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….smithy-gc.wasmneeds a host with WebAssembly GC that supplies the__moonbit_fs_unstableimports andspectest.print_char.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….
Smithy now loads smithy.contracts#conditions and validates JMESPath syntax, modeled member references, function arguments, and boolean results during assembly. The new moonrockz/jmespath package exposes standalone parsing, an inspectable AST with source spans, JSON evaluation, and diagnostics with source locations. IDL/JSON conversion preserves contract expressions and documentation. Serialization does not evaluate contracts. Existing models without contract traits need no changes.
🚀 Features
- Support Smithy contract traits (#21) by @DamianReeves
- Add public JMESPath parser and evaluator (#22) by @DamianReeves
- Analyze JMESPath contract conditions (#23) by @DamianReeves
🏗️ Build and CI
- Consume zig-cross from moonx-tools (#20) by @DamianReeves
Full changelog: v0.1.1...v0.2.0
v0.1.1
Install:
mise use github:moonrockz/smithy@0.1.1moon add moonrockz/smithy-syntax@0.1.1moonx moonrockz/zig-cross@0.1.1 --help
Wasm files:
smithy.wasmneeds a host that supplies the__moonbit_fs_unstableimports andwasi_snapshot_preview1.fd_write.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….smithy-gc.wasmneeds a host with WebAssembly GC that supplies the__moonbit_fs_unstableimports andspectest.print_char.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….
The Smithy CLI now uses moonbitlang/core/argparse for command-specific help and standard option syntax. Use smithy help convert, smithy convert --help or -h to see a command's options; inline forms such as --to=json and -omodel.json are supported. Release publishing now retries temporary moonx asset availability failures, and generated migration notes preserve wrapped text.
🐛 Bug fixes
- (release) Preserve wrapped migration notes (#15) by @DamianReeves
- (release) Retry moonx asset availability (#16) by @DamianReeves
- (cli) Use argparse for command help (#17) by @DamianReeves
Full changelog: v0.1.0...v0.1.1
v0.1.0
Install:
mise use github:moonrockz/smithy@0.1.0moon add moonrockz/smithy-syntax@0.1.0moonx moonrockz/zig-cross@0.1.0 --help
Wasm files:
smithy.wasmneeds a host that supplies the__moonbit_fs_unstableimports andwasi_snapshot_preview1.fd_write.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….smithy-gc.wasmneeds a host with WebAssembly GC that supplies the__moonbit_fs_unstableimports andspectest.print_char.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….
Smithy now assembles mixed IDL and JSON files into a semantic model and converts models in either direction. The CLI adds ast, validate, format and convert, and runs through moonx moonrockz/smithy-cli@0.1.0. Formatting preserves IDL comments; conversion emits flattened Smithy 2 models with exact numbers and one file per namespace. Parsing now rejects adjacent object and trait entries and reports corrected recovery locations. When upgrading from 0.0.1, import Piece and Step from scanner, and Depth and ParseError from parser; ShapeKind display now uses IDL keywords, and test helpers moved from lawkit to internal/lawkit.
⚠️ Breaking changes
- (syntax) Import
PieceandStepfromscanner, andDepthandParseErrorfromparser.ShapeKinddisplay uses IDL keywords. Test helpers moved fromlawkittointernal/lawkit. (#11)
🚀 Features
- (model) Add JSON AST codec and model assembly (#10) by @DamianReeves
- (cli) Add commands and model conversion (#12) by @DamianReeves
🐛 Bug fixes
- (syntax) [breaking] Harden parsing and traversal contracts (#11) by @DamianReeves
- (release) Correct publication and CLI checks (#13) by @DamianReeves
📚 Documentation
- (zig-cross) Link the upstream issues for the wrapper workarounds (#9) by @DamianReeves
🏗️ Build and CI
- Do not unset core.hooksPath in hooks:install (#4) by @DamianReeves
Full changelog: v0.0.1...v0.1.0
v0.0.1
Install:
mise use github:moonrockz/smithy@0.0.1moon add moonrockz/smithy-syntax@0.0.1moonx moonrockz/zig-cross@0.0.1 --help
Wasm files:
smithy.wasmneeds a host that supplies the__moonbit_fs_unstableimports andwasi_snapshot_preview1.fd_write.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….smithy-gc.wasmneeds a host with WebAssembly GC that supplies the__moonbit_fs_unstableimports andspectest.print_char.wasmtimealone fails withunknown import: __moonbit_fs_unstable::….
This is the first release of moonrockz/smithy. The moonrockz/smithy-syntax library parses Smithy IDL 1.0 and 2.0 into a lossless syntax tree and an AST, reports diagnostics with source carets, and gives several ways to walk the AST. The smithy command is available for Linux, macOS and Windows: install it with mise use github:moonrockz/smithy@0.0.1. In this release the command only prints its version. The new moonrockz/zig-cross tool cross-compiles MoonBit native programs with zig: run it with moonx moonrockz/zig-cross@0.0.1.
🚀 Features
- (syntax) Add the Smithy IDL syntax layer (moonrockz/smithy-syntax) (#5) by @DamianReeves
- (traversal) Add the IDL traversal package (#6) by @DamianReeves
- (release) Zig cross-compiled release pipeline (#7) by @DamianReeves
📚 Documentation
- Add the mise trust step to the agent setup instructions by @DamianReeves
🏗️ Build and CI
- Set up the MoonBit monorepo with mise and moonx task scripts (#1) by @DamianReeves
- Address the Codex review of the monorepo setup (#2) by @DamianReeves
- Manage git hooks with lefthook (#3) by @DamianReeves