[Checkins] [zopefoundation/zope.interface] 9267f7: Make verification errors more readable and useful.

Jason Madden noreply at github.com
Thu Feb 6 17:51:04 CET 2020


  Branch: refs/heads/issue170
  Home:   https://github.com/zopefoundation/zope.interface
  Commit: 9267f73a8c4df1563f99ea41d027b053e867f328
      https://github.com/zopefoundation/zope.interface/commit/9267f73a8c4df1563f99ea41d027b053e867f328
  Author: Jason Madden <jamadden at gmail.com>
  Date:   2020-02-06 (Thu, 06 Feb 2020)

  Changed paths:
    M CHANGES.rst
    M docs/verify.rst
    M src/zope/interface/exceptions.py
    M src/zope/interface/interface.py
    M src/zope/interface/tests/test_exceptions.py
    M src/zope/interface/tests/test_interface.py
    M src/zope/interface/verify.py

  Log Message:
  -----------
  Make verification errors more readable and useful.

Eliminate the trailing newlines and blank spaces (the code called them
"a stupid artifact").

Include the name of the defining interface (so the user can easily look up
any requirements on the attribute) and, for methods, the expected
signature (no more guessing about how many arguments are required!).

This is implemented by giving Attribute and Method useful reprs and strs.
Previously, they just had the defaults.

Fixes #170




More information about the checkins mailing list