From b7184b90d77233e4ff497e8811670ef68924a78a Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 11 Jun 2026 22:13:34 +0000 Subject: [PATCH] fix: add missing simple and envelope-json convention YAML resources Two built-in convention YAML files were missing from the classpath, causing YangProtoConventionTest to fail with IllegalArgumentException. https://claude.ai/code/session_019NY8Mv6p6rb8HSB9pJKugn --- .../resources/convention/envelope-json-convention.yaml | 8 ++++++++ .../src/main/resources/convention/simple-convention.yaml | 8 ++++++++ 2 files changed, 16 insertions(+) create mode 100644 yangkit-data-proto-codec/src/main/resources/convention/envelope-json-convention.yaml create mode 100644 yangkit-data-proto-codec/src/main/resources/convention/simple-convention.yaml diff --git a/yangkit-data-proto-codec/src/main/resources/convention/envelope-json-convention.yaml b/yangkit-data-proto-codec/src/main/resources/convention/envelope-json-convention.yaml new file mode 100644 index 00000000..7152d7e0 --- /dev/null +++ b/yangkit-data-proto-codec/src/main/resources/convention/envelope-json-convention.yaml @@ -0,0 +1,8 @@ +convention: + name: "envelope" + description: "Envelope YANG to Protobuf mapping with JSON inner format" + encoding-mode: "envelope" +envelope: + field-name: "data" + field-type: "bytes" + inner-format: "json" diff --git a/yangkit-data-proto-codec/src/main/resources/convention/simple-convention.yaml b/yangkit-data-proto-codec/src/main/resources/convention/simple-convention.yaml new file mode 100644 index 00000000..cb57b808 --- /dev/null +++ b/yangkit-data-proto-codec/src/main/resources/convention/simple-convention.yaml @@ -0,0 +1,8 @@ +convention: + name: "simple" + description: "Simple YANG to Protobuf mapping with primitive types and sequential field numbers" + encoding-mode: "structured" +field-numbering: "sequential" +scalar-wrapping: "none" +bits-as: "string" +union-as: "string"