[NETCONF-1058] Union type has wrong type Created: 15/Jun/23 Updated: 25/Sep/23 |
|
| Status: | In Progress |
| Project: | netconf |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 7.0.0 |
| Type: | Bug | Priority: | Medium |
| Reporter: | Tobias Pobocik | Assignee: | Tobias Pobocik |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | pick-next, pt | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Attachments: |
|
| Description |
module definition-test {
namespace "urn:definition-test";
prefix sample; typedef topology-ref {
type instance-identifier;
} container binary-container {
leaf binary-data {
type binary;
default "SGVsbG8gdGVzdCE=";
}
} container union-container {
leaf testUnion1 {
type union {
type int32;
type string;
}
default 5;
} leaf testUnion2 {
type union {
type string;
type boolean;
}
default false;
} leaf testUnion3 {
type union {
type int32;
type boolean;
}
default false;
} leaf testBoolean {
type boolean;
default true;
}
} container number-container {
leaf testInteger {
type int32;
default 42;
} leaf testUnsignedInteger {
type uint16;
default 100;
} leaf testDecimal {
type decimal64 {
fraction-digits 2;
}
default 3.14;
} leaf testDouble {
type decimal64 {
fraction-digits 11;
}
default 3.14159265359;
} leaf testInt64 {
type int64;
default 42;
} leaf testUint64 {
type uint64;
default 42;
}
} container enum-container {
leaf status {
type enumeration {
enum up {
value 1;
}
enum down {
value 2;
}
}
default "up";
}
} container network-container {
leaf network-ref {
type topology-ref;
default "/network/nodes[node-id='node1']";
}
}
}
When using union type for string and boolean as in the model, string value is registered instead of boolean. |
| Comments |
| Comment by Tobias Pobocik [ 23/Aug/23 ] |
|
This issue has been resolved in: |