DMTF / YANG-to-Redfish-Converter

This tool converts a YANG model file to the corresponding Redfish schema, specified in OData CSDL, in accordance with the YANG-to-CSDL Mapping Specification.
Other
4 stars 5 forks source link

Converting openconfig_vlan.yang results in a single CSDL file #19

Closed jcleung5549 closed 6 years ago

jcleung5549 commented 6 years ago

The console message indicates no problems

$ pyang --plugindir ./YANG-to-Redfish-Plugin --format redfish --path ./yangs --target_dir testdir yangs/openconfig-vlan
.yang
Success writing file to disk: testdir/openconfig_vlan_v1.xml

But the resultant file has minimal content. openconfig_vlan_v1.xml.txt

jcleung5549 commented 6 years ago

The YANG file openconfig-vlan.yang.txt

jcleung5549 commented 6 years ago

7/20 Running latest changes generates 36 CSDL files.

However, the following messages were displayed. I think there was a way to set the search path.

$ pyang --plugindir ./YANG-to-Redfish-Plugin --format redfish yangs/openconfig-vlan.yang
yangs/openconfig-vlan.yang:11: error: module "openconfig-vlan-types" not found in search path
yangs/openconfig-vlan.yang:12: error: module "openconfig-interfaces" not found in search path
yangs/openconfig-vlan.yang:13: error: module "openconfig-if-ethernet" not found in search path
yangs/openconfig-vlan.yang:13: warning: imported module openconfig-if-ethernet not used
yangs/openconfig-vlan.yang:14: error: module "openconfig-if-aggregate" not found in search path
yangs/openconfig-vlan.yang:14: warning: imported module openconfig-if-aggregate not used
yangs/openconfig-vlan.yang:16: error: module "openconfig-extensions" not found in search path
We don't recognize keyword, create as statement
tomasg2012 commented 6 years ago

Resolution with Network TF Meeting 8/24: Closing issue, and a new issue should be generated if the output is not as intended.