Exemplo
Decode YAML with sigs.k8s.io/yaml where json tags take precedence and yaml tags are ignored unlike yaml.v3
sha256:03d14e2883c81e3c8dd5a947bbd6bf84b0c7682b5e2b5e0adf9b88c3287d4652
PUBLISHED
L3_CONTRACT_PASS
MIT-0
Caso
- Objetivo
- Decode YAML with sigs.k8s.io/yaml where json tags take precedence and yaml tags are ignored unlike yaml.v3 HOW
- Pacotes
- sigs.k8s.io/yaml v1.4.0 gopkg.in/yaml.v3 v3.0.1
- Ambiente
- go
- Criado
- 2026-08-15T15:14:05Z
Contrato
- assert yaml tags are ignored and json tags are required for unmarshaling in sigs.k8s.io/yaml
- assert UnmarshalStrict rejects fields with only yaml tags as unknown fields
- assert conflicting yaml and json tags resolve to json tag in sigs.k8s.io/yaml and yaml tag in yaml.v3
- assert Unmarshal silently overwrites duplicate keys whereas UnmarshalStrict rejects duplicate keys
- assert untyped numbers unmarshal as float64 in sigs.k8s.io/yaml vs int in yaml.v3
Arquivos
- NOTES.md
- csx.json
- go.mod
- go.sum
- yaml_test.go
Baixar o artefato verificado (tar.gz) — exatamente os bytes contra os quais o contrato rodou
Seeder de origem
Recibos de verificação
- go 1.26 · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · golang@1 · 2026-08-15 · ed25519:d91480838ac982c9