Skip to content

Commit

Permalink
Fix some typos in doc strings (#218)
Browse files Browse the repository at this point in the history
  • Loading branch information
rtoijala authored and hynek committed Jul 20, 2017
1 parent 50107f6 commit 93c5d2a
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/attr/_funcs.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def asdict(inst, recurse=True, filter=None, dict_factory=dict,
:param inst: Instance of an ``attrs``-decorated class.
:param bool recurse: Recurse into classes that are also
``attrs``-decorated.
:param callable filter: A callable whose return code deteremines whether an
:param callable filter: A callable whose return code determines whether an
attribute or element is included (``True``) or dropped (``False``). Is
called with the :class:`attr.Attribute` as the first argument and the
value as the second argument.
Expand Down
10 changes: 5 additions & 5 deletions src/attr/_make.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def attr(default=NOTHING, validator=None,
excluded using ``init=False``.
If the value is an instance of :class:`Factory`, its callable will be
used to construct a new value (useful for mutable datatypes like lists
used to construct a new value (useful for mutable data types like lists
or dicts).
If a default is not set (or set manually to ``attr.NOTHING``), a value
Expand Down Expand Up @@ -256,7 +256,7 @@ def attributes(maybe_cls=None, these=None, repr_ns=None,
to automatically detect that. Therefore it's possible to set the
namespace explicitly for a more meaningful ``repr`` output.
:param bool repr: Create a ``__repr__`` method with a human readable
represantation of ``attrs`` attributes..
representation of ``attrs`` attributes..
:param bool str: Create a ``__str__`` method that is identical to
``__repr__``. This is usually not necessary except for
:class:`Exception`\ s.
Expand Down Expand Up @@ -284,7 +284,7 @@ def attributes(maybe_cls=None, these=None, repr_ns=None,
and the `GitHub issue that led to the default behavior \
<https://github.com/python-attrs/attrs/issues/136>`_ for more details.
:type hash: ``bool`` or ``None``
:param bool init: Create a ``__init__`` method that initialiazes the
:param bool init: Create a ``__init__`` method that initializes the
``attrs`` attributes. Leading underscores are stripped for the
argument name. If a ``__attrs_post_init__`` method exists on the
class, it will be called after the class is fully initialized.
Expand Down Expand Up @@ -627,7 +627,7 @@ def fields(cls):
:raise attr.exceptions.NotAnAttrsClassError: If *cls* is not an ``attrs``
class.
:rtype: tuple (with name accesors) of :class:`attr.Attribute`
:rtype: tuple (with name accessors) of :class:`attr.Attribute`
.. versionchanged:: 16.2.0 Returned tuple allows accessing the fields
by name.
Expand Down Expand Up @@ -1022,7 +1022,7 @@ def make_class(name, attrs, bases=(object,), **attributes_arguments):
return attributes(**attributes_arguments)(type(name, bases, cls_dict))


# These are required by whithin this module so we define them here and merely
# These are required by within this module so we define them here and merely
# import into .validators.


Expand Down
2 changes: 1 addition & 1 deletion src/attr/validators.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def __repr__(self):
def instance_of(type):
"""
A validator that raises a :exc:`TypeError` if the initializer is called
with a wrong type for this particular attribute (checks are perfomed using
with a wrong type for this particular attribute (checks are performed using
:func:`isinstance` therefore it's also valid to pass a tuple of types).
:param type: The type to check for.
Expand Down

0 comments on commit 93c5d2a

Please sign in to comment.