#42 Unknown global "children" in DocformatVisitor

open-fixed
None
2
2009-09-23
2005-05-16
No

In DocformatVisitor.visit_attribute (in
readers.python.__init__.py),
there is this:

for child in children:

but children has not yet been bound to anything there,
so a NameError is raised.

Discussion

  • Greg Chapman

    Greg Chapman - 2005-05-16

    Logged In: YES
    user_id=86307

    Also, a little later in the same method, there is this:

    name = name[1:-1]

    I believe that should be:

    name = value[1:-1]

    (name always equals "__docformat__", value has the literal
    string which is assigned to the __docformat__ attribute).

     
  • Felix Wiemann

    Felix Wiemann - 2005-05-18
    • assigned_to: nobody --> goodger
     
  • Felix Wiemann

    Felix Wiemann - 2005-05-18

    Logged In: YES
    user_id=1014490

    Assigned to David; he knows the Python-source-reader code
    best, I suppose.

     
  • Oaktuckian

    Oaktuckian - 2006-02-28

    Logged In: YES
    user_id=1167097

    Simple fix for DocformatVisitor.. children becomes node.

     
  • Oaktuckian

    Oaktuckian - 2006-02-28
    • status: open --> open-fixed
     
  • Felix Wiemann

    Felix Wiemann - 2006-02-28
    • assigned_to: goodger --> oaktuckian
     
  • Felix Wiemann

    Felix Wiemann - 2006-02-28

    Logged In: YES
    user_id=1374215

    The fix is currently on the nesting branch; when Tad has
    checked in a unit test, it should probably be moved to the
    trunk (I can do that). I'll leave this bug open till this
    is done.

     
  • Günter Milde

    Günter Milde - 2009-09-11
    • priority: 5 --> 3
     
  • Günter Milde

    Günter Milde - 2009-09-23
    • priority: 3 --> 2
     

Log in to post a comment.