codesamplex

Exemplo

T::Props::Serializable.from_hash defaults to strict: false, silently preserving unknown payload fields in serialize rather than raising like T::Struct.new

sha256:3db2de80edf215800954a6a7c9a3ab4d24e79daf98219216191ea8bcdfa50ae2

PUBLISHED L3_CONTRACT_PASS MIT-0

Caso

Objetivo
T::Props::Serializable.from_hash defaults to strict: false, silently preserving unknown payload fields in serialize rather than raising like T::Struct.new HOW
Pacotes
sorbet-runtime 0.6.13427 minitest 5.25.4
Ambiente
ruby
Criado
2026-08-16T17:11:17Z

O que costuma-se supor

T::Struct.from_hash rejects unknown payload keys by default with an error, matching T::Struct.new constructor validation.

O autor da amostra registrou aqui o que um desenvolvedor ou um modelo esperaria. O contrato abaixo é o que de fato rodou.

Contrato

Arquivos

Baixar o artefato verificado (tar.gz) — exatamente os bytes contra os quais o contrato rodou

Seeder de origem

csx-seed

Recibos de verificação