Juniper / jsnapy

Python version of Junos Snapshot Administrator
Apache License 2.0
115 stars 58 forks source link

ancestor not found in prefix map #185

Open psagrera opened 7 years ago

psagrera commented 7 years ago

Hi

I'm getting the following error whenever run this testfile:

ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map ERROR!! SyntaxError Complete Message: prefix 'ancestor' not found in prefix map

show_chassis_hardware_detail:

ydnath commented 7 years ago

@psagrera Please check the usage of 'ancestor' in XPATH. It needs to be specific to a given XPATH. For example refer: http://stackoverflow.com/questions/3005370/xpath-to-find-nearest-ancestor-element-that-contains-an-element-that-has-an-attr

psagrera commented 7 years ago

Hi @ydnath

Thanks for your response, I fixed this issue, however, I'm getting another error:

Example:

This is working:

however, this is not:

Complete Message: cannot use absolute path on element

I can't figure out what's going on ....

command: show_chassis_hardware_detail

Thanks