Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Execution ends up with a runtime error #8

Closed
GoogleCodeExporter opened this issue Mar 16, 2015 · 2 comments
Closed

Execution ends up with a runtime error #8

GoogleCodeExporter opened this issue Mar 16, 2015 · 2 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
While running pyang on the attached example a runtime error occurs. The
grammar of the test case is not correct. The 'uses' statement is used under
the 'leaf'.

What do you see instead?
Traceback (most recent call last):
  File "/usr/bin/pyang", line 186, in <module>
    run()
  File "/usr/bin/pyang", line 139, in run
    module = ctx.add_module(filename, text)
  File "/usr/lib/python2.5/site-packages/pyang/__init__.py", line 44, in
add_module
    module = self._add_module(ref, text, format)
  File "/usr/lib/python2.5/site-packages/pyang/__init__.py", line 83, in
_add_module
    statements.validate_module(self, module)
  File "/usr/lib/python2.5/site-packages/pyang/statements.py", line 76, in
validate_module
    iterate(module, phase)
  File "/usr/lib/python2.5/site-packages/pyang/statements.py", line 39, in
iterate
    res = f(ctx, stmt)
  File "/usr/lib/python2.5/site-packages/pyang/statements.py", line 158, in
<lambda>
    ('expand_1', 'module'):lambda ctx, s: v_expand_1_children(ctx, s),
  File "/usr/lib/python2.5/site-packages/pyang/statements.py", line 910, in
v_expand_1_children
    v_expand_1_children(ctx, s)
  File "/usr/lib/python2.5/site-packages/pyang/statements.py", line 908, in
v_expand_1_children
    v_expand_1_children(ctx, s)
  File "/usr/lib/python2.5/site-packages/pyang/statements.py", line 905, in
v_expand_1_children
    v_expand_1_uses(ctx, s)
  File "/usr/lib/python2.5/site-packages/pyang/statements.py", line 916, in
v_expand_1_uses
    if stmt.i_grouping is None:
AttributeError: 'Statement' object has no attribute 'i_grouping'

What version of the product are you using? On what operating system?
pyang 0.9.3


Original issue reported on code.google.com by kur...@gmail.com on 18 Apr 2009 at 12:19

Attachments:

@GoogleCodeExporter
Copy link
Author

Original comment by mbj4...@gmail.com on 19 Apr 2009 at 11:01

  • Changed state: Accepted

@GoogleCodeExporter
Copy link
Author

Original comment by mbj4...@gmail.com on 20 Apr 2009 at 6:43

  • Changed state: Fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant