summaryrefslogtreecommitdiff
path: root/astroid/helpers.py
diff options
context:
space:
mode:
authorCeridwen <ceridwenv@gmail.com>2015-11-02 00:10:54 -0500
committerCeridwen <ceridwenv@gmail.com>2015-11-02 00:10:54 -0500
commit1ba0f2d96fbc45ff0b6014b12db98716183e8277 (patch)
tree54b7c4d3ecad6fcda1211ea3a8e5f11f6b407287 /astroid/helpers.py
parent83f6c45c343cae87f415268959b1056030a5e74c (diff)
downloadastroid-1ba0f2d96fbc45ff0b6014b12db98716183e8277.tar.gz
This bookmark adds structured exceptions to astroid.
Major changes: * AstroidError has an __init__ that accepts arbitrary keyword-only arguments for adding information to exceptions, and a __str__ that lazily uses exception attributes to generate a message. The first positional argument to an exception is assigned to .message. The new API should be fully backwards compatible in general. * Some exceptions are combined or renamed; the old names are still available. * The OperationErrors used by pylint are now BadOperationMessages and located in util.py. * The AstroidBuildingException in _data_build stores the SyntaxError in its .error attribute rather than args[0]. * Many places where exceptions are raised have new, hopefully more useful error messages. The only major issue remaining is how to propagate information into decorators.
Diffstat (limited to 'astroid/helpers.py')
-rw-r--r--astroid/helpers.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/astroid/helpers.py b/astroid/helpers.py
index 00f4784..d4cd0dd 100644
--- a/astroid/helpers.py
+++ b/astroid/helpers.py
@@ -86,7 +86,7 @@ def object_type(node, context=None):
This is used to implement the ``type`` builtin, which means that it's
used for inferring type calls, as well as used in a couple of other places
- in the inference.
+ in the inference.
The node will be inferred first, so this function can support all
sorts of objects, as long as they support inference.
"""