Sample
Parse and serialize Ruby data structures with JSON.[] dispatch, decimal_class precision, custom container classes, streaming JSON.dump depth checks, and core type additions
sha256:a87be603acbde77905b8b59ae00abe846be04ddcac05e754dcc29647170a50de
PUBLISHED
L3_CONTRACT_PASS
MIT-0
Execution evidence
Declared environment and signed verification runs are separated so you can see exactly what this sample proves.
Evidence basisSigned contract pass
Verification receipts1
Verification levelL3_CONTRACT_PASS
Declared environment
- Execution context
- ruby
- Operating system
- linux
- Architecture
- x64
- Runtime
- ruby
- Language
- ruby
- Package manager
- rubygems
Verification-run environments
- Execution context
- ruby 3
- Operating system
- linux debian · glibc
- Architecture
- x64
- Runtime
- ruby 3
- Language
- ruby
- Package manager
- rubygems
- Execution
- container · docker
CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · rubygems@1 · 2026-08-17
Case
- Goal
- Parse and serialize Ruby data structures with JSON.[] dispatch, decimal_class precision, custom container classes, streaming JSON.dump depth checks, and core type additions HOW
- Packages
-
json 2.9.1
- Environment
- ruby
- Created
- 2026-08-17T12:28:09Z
Contract
- assert JSON.[] operates as a polymorphic dispatch method that delegates String arguments to JSON.parse and non-String Ruby objects to JSON.generate
- assert JSON.parse with decimal_class: BigDecimal preserves exact arbitrary-precision decimal representations without IEEE 754 float rounding loss
- assert JSON.parse supports custom collection containers via array_class and object_class
- assert JSON.dump streams serialized output directly to IO destinations when provided and enforces strict recursion depth limits raising ArgumentError when exceeded
- assert requiring json/add core extensions enables bidirectional JSON serialization for Time, Date, Struct, Set, and Symbol types using create_additions: true
- assert JSON.create_id configures the addition type identifier attribute and setting custom values alters the tag matched during deserialization
Files
- Gemfile
- Gemfile.lock
- NOTES.md
- csx.json
- src/json_features.rb
- test/contract.rb
Download the source artifact (tar.gz)
Origin Seeder
csx-seed
Verification receipts
- ruby 3 · linux debian/x64 · docker · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · rubygems@1 · 2026-08-17 · ed25519:d91480838ac982c9