Menu

#6 Get Class 'module' attribute right

open
nobody
None
5
2002-03-01
2002-03-01
Greg Ward
No

This patch fixes bug #524393 by 1) getting
the 'module' attribute of a new Class instance
right, and 2) skipping _findClassWarnings() on
classes defined in a module other than the one
currently being checked.

Discussion

  • Greg Ward

    Greg Ward - 2002-03-01
     
  • Greg Ward

    Greg Ward - 2002-03-01

    Logged In: YES
    user_id=14422

    Oops. That patch fell down and went boom as soon
    as it got close to a real-life ExtensionClass. Sigh.
    New version attached.

     
  • Greg Ward

    Greg Ward - 2002-03-01
     
  • Neal Norwitz

    Neal Norwitz - 2002-03-05

    Logged In: YES
    user_id=33168

    I think the bug is now fixed (in a different way).
    But there seems to be some good elements of this patch.

     
  • Greg Ward

    Greg Ward - 2002-03-05

    Logged In: YES
    user_id=14422

    No, as near as I can tell bug #524393 is still alive
    in the current CVS code. This patch, or something like
    it, is needed to kill that bug.

     
  • Neal Norwitz

    Neal Norwitz - 2002-03-08

    Logged In: YES
    user_id=33168

    I applied the patch to checker.py and there is no problems
    with the regression tests. However, when applying the patch
    to warn.py (if c.module is module:), many tests fail.

    I tested with 2.1.

     
  • Greg Ward

    Greg Ward - 2002-03-27

    Logged In: YES
    user_id=14422

    I'm uploading a revised version of this patch that
    only includes the part Neal hasn't already accepted.

     
  • Greg Ward

    Greg Ward - 2002-03-27

    Logged In: YES
    user_id=14422

    I'm uploading a revised version of this patch that
    only includes the part Neal hasn't already
    accepted.

     
  • Greg Ward

    Greg Ward - 2002-03-27
     
  • Neal Norwitz

    Neal Norwitz - 2002-03-27

    Logged In: YES
    user_id=33168

    When I run this patch on 2.2 I get lots of errors.
    Is there anything else other than
    if c.module is module:
    added?

    test28 is a short one that fails for me with 2.2,
    but I think everything works with 2.1.

     
  • Greg Ward

    Greg Ward - 2002-03-27
     
  • Greg Ward

    Greg Ward - 2002-03-27

    Logged In: YES
    user_id=14422

    OOOPS! This patch has been broken all along.
    "c.module is module" should have been "c.module is
    module.module" -- DOHH!

    That might explain why some PyChecker tests
    failed. It certainly explains some problems I
    have been having. Uploading yet another version
    of the patch.

     
  • Neal Norwitz

    Neal Norwitz - 2002-06-06

    Logged In: YES
    user_id=33168

    I think I'm going to use this patch, but as a cmd line option.
    So if the user uses the option it means
    "only return warnings from files I pass on the command line."
    Otherwise, check all files (as it does today).

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.