acidjunk / pyang

Automatically exported from code.google.com/p/pyang
ISC License
0 stars 0 forks source link

augment fails for two level inheritance #91

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. run pyang like "pyang -f uml ./base.yang ./derived.yang ./concrete.yang -o 
concrete.uml
2. Throws an error saying "./concrete.yang:12: error: node derived::b is not 
found".

What is the expected output? What do you see instead?

I expect container "b" to have both "derived:test1" and "concrete:test2" in 
concrete.yang (a simple two level inheritance).

What version of the product are you using? On what operating system?
pyang 1.3
Linux (ubuntu 13.04 server) x86_64 Kernel 3.8.0-19-generic

Please provide any additional information below.

I also tried the following variations.

[1] Removed container a in base.yang. Tried to use the following in 
concrete.yang

augment "/derived:b" {
     leaf test2 { type empty; }
}

Still the same issue. pyang complains that "/derived:b" not found.

[2] Tried providing all "derived" inheritance in concrete.yang

augment "/derived:a/derived:b" {
      leaf test2 { type empty; }
}

Still the same issue.

Original issue reported on code.google.com by harihara...@gmail.com on 6 Jun 2013 at 5:09

Attachments:

GoogleCodeExporter commented 9 years ago
Hi,

The problem is that concrete augments /base:a/derived:b, but there is no node 
"derived:b".  base defines /base:a/base:b and derived defines 
/base:a/base:b/derived:test1.

/martin

Original comment by mbj4...@gmail.com on 7 Jun 2013 at 10:21