]> git.notmuchmail.org Git - notmuch/commitdiff
python/notmuch2: fix typo for "destroyed"
authorDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Mon, 23 Dec 2019 21:06:48 +0000 (16:06 -0500)
committerDavid Bremner <david@tethera.net>
Mon, 23 Dec 2019 22:13:09 +0000 (07:13 +0900)
Another fix to the docstrings, this time for the English part of the
docstrings, not the Python class name.  No functional changes here.

Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
bindings/python-cffi/notmuch2/_database.py
bindings/python-cffi/notmuch2/_errors.py
bindings/python-cffi/notmuch2/_message.py
bindings/python-cffi/notmuch2/_thread.py

index 7ef4fe170e23bfeba22f340d12806cd8c62b8785..95f59ca037bba01f60d522356987e528024316f2 100644 (file)
@@ -262,7 +262,7 @@ class Database(base.NotmuchObject):
 
         This is returned as a :class:`pathlib.Path` instance.
 
 
         This is returned as a :class:`pathlib.Path` instance.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         try:
             return self._cache_path
         """
         try:
             return self._cache_path
@@ -277,7 +277,7 @@ class Database(base.NotmuchObject):
 
         This is a positive integer.
 
 
         This is a positive integer.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         try:
             return self._cache_version
         """
         try:
             return self._cache_version
@@ -296,7 +296,7 @@ class Database(base.NotmuchObject):
 
         A read-only database will never be upgradable.
 
 
         A read-only database will never be upgradable.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_database_needs_upgrade(self._db_p)
         return bool(ret)
         """
         ret = capi.lib.notmuch_database_needs_upgrade(self._db_p)
         return bool(ret)
@@ -320,7 +320,7 @@ class Database(base.NotmuchObject):
            not imply durability, it only ensures the changes are
            performed atomically.
 
            not imply durability, it only ensures the changes are
            performed atomically.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ctx = AtomicContext(self, '_db_p')
         return ctx
         """
         ctx = AtomicContext(self, '_db_p')
         return ctx
@@ -330,7 +330,7 @@ class Database(base.NotmuchObject):
 
         Returned as a ``(revision, uuid)`` namedtuple.
 
 
         Returned as a ``(revision, uuid)`` namedtuple.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         raw_uuid = capi.ffi.new('char**')
         rev = capi.lib.notmuch_database_get_revision(self._db_p, raw_uuid)
         """
         raw_uuid = capi.ffi.new('char**')
         rev = capi.lib.notmuch_database_get_revision(self._db_p, raw_uuid)
@@ -387,7 +387,7 @@ class Database(base.NotmuchObject):
            READ_ONLY mode.
         :raises UpgradeRequiredError: The database must be upgraded
            first.
            READ_ONLY mode.
         :raises UpgradeRequiredError: The database must be upgraded
            first.
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         if not hasattr(os, 'PathLike') and isinstance(filename, pathlib.Path):
             filename = bytes(filename)
         """
         if not hasattr(os, 'PathLike') and isinstance(filename, pathlib.Path):
             filename = bytes(filename)
@@ -426,7 +426,7 @@ class Database(base.NotmuchObject):
            READ_ONLY mode.
         :raises UpgradeRequiredError: The database must be upgraded
            first.
            READ_ONLY mode.
         :raises UpgradeRequiredError: The database must be upgraded
            first.
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         if not hasattr(os, 'PathLike') and isinstance(filename, pathlib.Path):
             filename = bytes(filename)
         """
         if not hasattr(os, 'PathLike') and isinstance(filename, pathlib.Path):
             filename = bytes(filename)
@@ -458,7 +458,7 @@ class Database(base.NotmuchObject):
         :raises OutOfMemoryError: When there is no memory to allocate
            the message instance.
         :raises XapianError: A Xapian exception ocurred.
         :raises OutOfMemoryError: When there is no memory to allocate
            the message instance.
         :raises XapianError: A Xapian exception ocurred.
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         msg_pp = capi.ffi.new('notmuch_message_t **')
         ret = capi.lib.notmuch_database_find_message(self._db_p,
         """
         msg_pp = capi.ffi.new('notmuch_message_t **')
         ret = capi.lib.notmuch_database_find_message(self._db_p,
@@ -489,7 +489,7 @@ class Database(base.NotmuchObject):
         :raises OutOfMemoryError: When there is no memory to allocate
            the message instance.
         :raises XapianError: A Xapian exception ocurred.
         :raises OutOfMemoryError: When there is no memory to allocate
            the message instance.
         :raises XapianError: A Xapian exception ocurred.
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         if not hasattr(os, 'PathLike') and isinstance(filename, pathlib.Path):
             filename = bytes(filename)
         """
         if not hasattr(os, 'PathLike') and isinstance(filename, pathlib.Path):
             filename = bytes(filename)
@@ -522,7 +522,7 @@ class Database(base.NotmuchObject):
 
         :rtype: ImmutableTagSet
 
 
         :rtype: ImmutableTagSet
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         try:
             ref = self._cached_tagset
         """
         try:
             ref = self._cached_tagset
@@ -570,7 +570,7 @@ class Database(base.NotmuchObject):
 
         :raises OutOfMemoryError: if no memory is available to
            allocate the query.
 
         :raises OutOfMemoryError: if no memory is available to
            allocate the query.
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         query = self._create_query(query,
                                    omit_excluded=omit_excluded,
         """
         query = self._create_query(query,
                                    omit_excluded=omit_excluded,
@@ -587,7 +587,7 @@ class Database(base.NotmuchObject):
         :returns: An iterator over the messages found.
         :rtype: MessageIter
 
         :returns: An iterator over the messages found.
         :rtype: MessageIter
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         query = self._create_query(query,
                                    omit_excluded=omit_excluded,
         """
         query = self._create_query(query,
                                    omit_excluded=omit_excluded,
@@ -635,7 +635,7 @@ class AtomicContext:
        section is not active.  When it is raised at exit time the
        atomic section is still active and you may need to try using
        :meth:`force_end`.
        section is not active.  When it is raised at exit time the
        atomic section is still active and you may need to try using
        :meth:`force_end`.
-    :raises ObjectDestroyedError: if used after destoryed.
+    :raises ObjectDestroyedError: if used after destroyed.
     """
 
     def __init__(self, db, ptr_name):
     """
 
     def __init__(self, db, ptr_name):
@@ -675,7 +675,7 @@ class AtomicContext:
            not ended.
         :raises UnbalancedAtomicError: If the database was currently
            not in an atomic section.
            not ended.
         :raises UnbalancedAtomicError: If the database was currently
            not in an atomic section.
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_database_end_atomic(self._ptr())
         if ret != capi.lib.NOTMUCH_STATUS_SUCCESS:
         """
         ret = capi.lib.notmuch_database_end_atomic(self._ptr())
         if ret != capi.lib.NOTMUCH_STATUS_SUCCESS:
index 1c88763b95d1daa22f3d094c640360ec34149b04..13369445ffabd0b309f0a7a731335bf8b531a5ca 100644 (file)
@@ -97,7 +97,7 @@ class IllegalArgumentError(NotmuchError): pass
 
 
 class ObjectDestroyedError(NotmuchError):
 
 
 class ObjectDestroyedError(NotmuchError):
-    """The object has already been destoryed and it's memory freed.
+    """The object has already been destroyed and it's memory freed.
 
     This occurs when :meth:`destroy` has been called on the object but
     you still happen to have access to the object.  This should not
 
     This occurs when :meth:`destroy` has been called on the object but
     you still happen to have access to the object.  This should not
index bb5614260e8046a1ceb4e7b3450d0200ab684939..c5fdbf6df94a635853d45daf18feec7b51550467 100644 (file)
@@ -98,7 +98,7 @@ class Message(base.NotmuchObject):
            bytes() on it will return the original bytes used to create
            it.
 
            bytes() on it will return the original bytes used to create
            it.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_message_get_message_id(self._msg_p)
         return base.BinString(capi.ffi.string(ret))
         """
         ret = capi.lib.notmuch_message_get_message_id(self._msg_p)
         return base.BinString(capi.ffi.string(ret))
@@ -116,7 +116,7 @@ class Message(base.NotmuchObject):
            bytes() on it will return the original bytes used to create
            it.
 
            bytes() on it will return the original bytes used to create
            it.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_message_get_thread_id(self._msg_p)
         return base.BinString(capi.ffi.string(ret))
         """
         ret = capi.lib.notmuch_message_get_thread_id(self._msg_p)
         return base.BinString(capi.ffi.string(ret))
@@ -128,7 +128,7 @@ class Message(base.NotmuchObject):
         If multiple files in the database contain the same message ID
         this will be just one of the files, chosen at random.
 
         If multiple files in the database contain the same message ID
         this will be just one of the files, chosen at random.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_message_get_filename(self._msg_p)
         return pathlib.Path(os.fsdecode(capi.ffi.string(ret)))
         """
         ret = capi.lib.notmuch_message_get_filename(self._msg_p)
         return pathlib.Path(os.fsdecode(capi.ffi.string(ret)))
@@ -140,7 +140,7 @@ class Message(base.NotmuchObject):
         See :attr:`path` for details, this is the same but does return
         the path as a bytes object which is faster but less convenient.
 
         See :attr:`path` for details, this is the same but does return
         the path as a bytes object which is faster but less convenient.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_message_get_filename(self._msg_p)
         return capi.ffi.string(ret)
         """
         ret = capi.lib.notmuch_message_get_filename(self._msg_p)
         return capi.ffi.string(ret)
@@ -155,7 +155,7 @@ class Message(base.NotmuchObject):
         :returns: Iterator yielding :class:`pathlib.Path` instances.
         :rtype: iter
 
         :returns: Iterator yielding :class:`pathlib.Path` instances.
         :rtype: iter
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         fnames_p = capi.lib.notmuch_message_get_filenames(self._msg_p)
         return PathIter(self, fnames_p)
         """
         fnames_p = capi.lib.notmuch_message_get_filenames(self._msg_p)
         return PathIter(self, fnames_p)
@@ -169,7 +169,7 @@ class Message(base.NotmuchObject):
         :returns: Iterator yielding :class:`bytes` instances.
         :rtype: iter
 
         :returns: Iterator yielding :class:`bytes` instances.
         :rtype: iter
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         fnames_p = capi.lib.notmuch_message_get_filenames(self._msg_p)
         return FilenamesIter(self, fnames_p)
         """
         fnames_p = capi.lib.notmuch_message_get_filenames(self._msg_p)
         return FilenamesIter(self, fnames_p)
@@ -184,7 +184,7 @@ class Message(base.NotmuchObject):
         :attr:`messageid` and :attr:`threadid` attributes are valid
         for it.
 
         :attr:`messageid` and :attr:`threadid` attributes are valid
         for it.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_message_get_flag(
             self._msg_p, capi.lib.NOTMUCH_MESSAGE_FLAG_GHOST)
         """
         ret = capi.lib.notmuch_message_get_flag(
             self._msg_p, capi.lib.NOTMUCH_MESSAGE_FLAG_GHOST)
@@ -201,7 +201,7 @@ class Message(base.NotmuchObject):
         these messages to be flagged, which results in this property
         being set to *True*.
 
         these messages to be flagged, which results in this property
         being set to *True*.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_message_get_flag(
             self._msg_p, capi.lib.NOTMUCH_MESSAGE_FLAG_EXCLUDED)
         """
         ret = capi.lib.notmuch_message_get_flag(
             self._msg_p, capi.lib.NOTMUCH_MESSAGE_FLAG_EXCLUDED)
@@ -216,7 +216,7 @@ class Message(base.NotmuchObject):
         message's header, you can get the original header value with
         :meth:`header`.
 
         message's header, you can get the original header value with
         :meth:`header`.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         return capi.lib.notmuch_message_get_date(self._msg_p)
 
         """
         return capi.lib.notmuch_message_get_date(self._msg_p)
 
@@ -240,7 +240,7 @@ class Message(base.NotmuchObject):
 
         :raises LookupError: if the header is not present.
         :raises NullPointerError: For unexpected notmuch errors.
 
         :raises LookupError: if the header is not present.
         :raises NullPointerError: For unexpected notmuch errors.
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         # The returned is supposedly guaranteed to be UTF-8.  Header
         # names must be ASCII as per RFC x822.
         """
         # The returned is supposedly guaranteed to be UTF-8.  Header
         # names must be ASCII as per RFC x822.
@@ -263,7 +263,7 @@ class Message(base.NotmuchObject):
 
         :raises ReadOnlyDatabaseError: When manipulating tags on a
            database opened in read-only mode.
 
         :raises ReadOnlyDatabaseError: When manipulating tags on a
            database opened in read-only mode.
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         try:
             ref = self._cached_tagset
         """
         try:
             ref = self._cached_tagset
@@ -297,7 +297,7 @@ class Message(base.NotmuchObject):
         :raises UnbalancedFreezeThawError: if you somehow managed to
            call __exit__ of this context manager more than once.  Why
            did you do that?
         :raises UnbalancedFreezeThawError: if you somehow managed to
            call __exit__ of this context manager more than once.  Why
            did you do that?
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_message_freeze(self._msg_p)
         if ret != capi.lib.NOTMUCH_STATUS_SUCCESS:
         """
         ret = capi.lib.notmuch_message_freeze(self._msg_p)
         if ret != capi.lib.NOTMUCH_STATUS_SUCCESS:
index a754749fd09071e1a56dbe558c261a545621c4c6..bb76f2dc284a596eaa5992443a3bd3fb7b468ce9 100644 (file)
@@ -42,7 +42,7 @@ class Thread(base.NotmuchObject, collections.abc.Iterable):
     def threadid(self):
         """The thread ID as a :class:`BinString`.
 
     def threadid(self):
         """The thread ID as a :class:`BinString`.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_thread_get_thread_id(self._thread_p)
         return base.BinString.from_cffi(ret)
         """
         ret = capi.lib.notmuch_thread_get_thread_id(self._thread_p)
         return base.BinString.from_cffi(ret)
@@ -50,7 +50,7 @@ class Thread(base.NotmuchObject, collections.abc.Iterable):
     def __len__(self):
         """Return the number of messages in the thread.
 
     def __len__(self):
         """Return the number of messages in the thread.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         return capi.lib.notmuch_thread_get_total_messages(self._thread_p)
 
         """
         return capi.lib.notmuch_thread_get_total_messages(self._thread_p)
 
@@ -59,7 +59,7 @@ class Thread(base.NotmuchObject, collections.abc.Iterable):
 
         :returns: An iterator yielding :class:`Message` instances.
 
 
         :returns: An iterator yielding :class:`Message` instances.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         msgs_p = capi.lib.notmuch_thread_get_toplevel_messages(self._thread_p)
         return message.MessageIter(self, msgs_p, db=self._db)
         """
         msgs_p = capi.lib.notmuch_thread_get_toplevel_messages(self._thread_p)
         return message.MessageIter(self, msgs_p, db=self._db)
@@ -69,7 +69,7 @@ class Thread(base.NotmuchObject, collections.abc.Iterable):
 
         :returns: An iterator yielding :class:`Message` instances.
 
 
         :returns: An iterator yielding :class:`Message` instances.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         msgs_p = capi.lib.notmuch_thread_get_messages(self._thread_p)
         return message.MessageIter(self, msgs_p, db=self._db)
         """
         msgs_p = capi.lib.notmuch_thread_get_messages(self._thread_p)
         return message.MessageIter(self, msgs_p, db=self._db)
@@ -82,7 +82,7 @@ class Thread(base.NotmuchObject, collections.abc.Iterable):
         which did directly match the search query which this thread
         originates from.
 
         which did directly match the search query which this thread
         originates from.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         return capi.lib.notmuch_thread_get_matched_messages(self._thread_p)
 
         """
         return capi.lib.notmuch_thread_get_matched_messages(self._thread_p)
 
@@ -100,7 +100,7 @@ class Thread(base.NotmuchObject, collections.abc.Iterable):
         :returns: The stringified list of authors.
         :rtype: BinString
 
         :returns: The stringified list of authors.
         :rtype: BinString
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_thread_get_authors(self._thread_p)
         return base.BinString.from_cffi(ret)
         """
         ret = capi.lib.notmuch_thread_get_authors(self._thread_p)
         return base.BinString.from_cffi(ret)
@@ -115,7 +115,7 @@ class Thread(base.NotmuchObject, collections.abc.Iterable):
         :returns: The thread's subject.
         :rtype: BinString
 
         :returns: The thread's subject.
         :rtype: BinString
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         ret = capi.lib.notmuch_thread_get_subject(self._thread_p)
         return base.BinString.from_cffi(ret)
         """
         ret = capi.lib.notmuch_thread_get_subject(self._thread_p)
         return base.BinString.from_cffi(ret)
@@ -127,7 +127,7 @@ class Thread(base.NotmuchObject, collections.abc.Iterable):
         The time the first message was sent as an integer number of
         seconds since the *epoch*, 1 Jan 1970.
 
         The time the first message was sent as an integer number of
         seconds since the *epoch*, 1 Jan 1970.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         return capi.lib.notmuch_thread_get_oldest_date(self._thread_p)
 
         """
         return capi.lib.notmuch_thread_get_oldest_date(self._thread_p)
 
@@ -138,7 +138,7 @@ class Thread(base.NotmuchObject, collections.abc.Iterable):
         The time the last message was sent as an integer number of
         seconds since the *epoch*, 1 Jan 1970.
 
         The time the last message was sent as an integer number of
         seconds since the *epoch*, 1 Jan 1970.
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         return capi.lib.notmuch_thread_get_newest_date(self._thread_p)
 
         """
         return capi.lib.notmuch_thread_get_newest_date(self._thread_p)
 
@@ -160,7 +160,7 @@ class Thread(base.NotmuchObject, collections.abc.Iterable):
 
         :rtype: ImmutableTagSet
 
 
         :rtype: ImmutableTagSet
 
-        :raises ObjectDestroyedError: if used after destoryed.
+        :raises ObjectDestroyedError: if used after destroyed.
         """
         try:
             ref = self._cached_tagset
         """
         try:
             ref = self._cached_tagset