• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

openconfig / ygnmi / 18574443117

16 Oct 2025 08:50PM UTC coverage: 4.438% (-0.8%) from 5.235%
18574443117

push

github

web-flow
Panic on GNMI delete with union leafs (#167)

This patch modifies `pathgen/gnmigen.go` to check if the reflect value is valid before calling IsZero(). In the case of YANG union values, an uninitialized interface can be passed to reflect.ValueOf() which is one of the few cases it can return a zero value. This condition seems to exist only when a GNMI message is received that contains enough for a struct to be allocated but not enough for values to be populated (DELETE on a YANG keyed list).

A new test case is added to `ygnmi/ygnmi_test.go` which utilizes the modified YANG schema in `pathgen/testdata/yang/openconfig-unione.yang` to trigger the failure.

2 of 8107 new or added lines in 42 files covered. (0.02%)

2 existing lines in 2 files now uncovered.

2313 of 52114 relevant lines covered (4.44%)

0.05 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/exampleoc/exampleocpath/exampleocpath.go


Source Not Available

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc