Development of an internal social media platform with personalised dashboards for students
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

crash_missing_module_type.py 469B

123456789101112131415161718
  1. """ Test for a crash found in
  2. https://bitbucket.org/logilab/astroid/issue/45/attributeerror-module-object-has-no#comment-11944673
  3. """
  4. # pylint: disable=no-init, invalid-name, too-few-public-methods, redefined-outer-name
  5. def decor(trop):
  6. """ decorator """
  7. return trop
  8. class Foo(object):
  9. """ Class """
  10. @decor
  11. def prop(self):
  12. """ method """
  13. return self
  14. if __name__ == '__main__':
  15. trop = Foo()
  16. trop.prop = 42