aboutsummaryrefslogtreecommitdiff
path: root/bindings/python/docs/source
diff options
context:
space:
mode:
authorDavid Bremner <david@tethera.net>2025-02-15 15:30:43 -0400
committerDavid Bremner <david@tethera.net>2025-02-22 07:01:47 -0400
commitd526797ad198e394bb8b4909f43976b76fb347f1 (patch)
treeb924eefb8a1278afb988387a67e9fe413738003e /bindings/python/docs/source
parent9782c8651192c1496541bd8949b7991c41528b3f (diff)
python: move legacy python bindings to contrib.
This forces us to verify the build and test suite completes without the legacy python bindings. As of this commit the legacy python bindings are unsupported by notmuch. They are provided in contrib/ for now, but will most likely eventually be removed from there as well. We recommend that downstream/distro packagers phase out their packages for the legacy python bindings.
Diffstat (limited to 'bindings/python/docs/source')
-rw-r--r--bindings/python/docs/source/conf.py209
-rw-r--r--bindings/python/docs/source/database.rst54
-rw-r--r--bindings/python/docs/source/filesystem.rst32
-rw-r--r--bindings/python/docs/source/index.rst36
-rw-r--r--bindings/python/docs/source/message.rst54
-rw-r--r--bindings/python/docs/source/messages.rst15
-rw-r--r--bindings/python/docs/source/notes.rst6
-rw-r--r--bindings/python/docs/source/query.rst43
-rw-r--r--bindings/python/docs/source/quickstart.rst19
-rw-r--r--bindings/python/docs/source/status_and_errors.rst57
-rw-r--r--bindings/python/docs/source/tags.rst17
-rw-r--r--bindings/python/docs/source/thread.rst26
-rw-r--r--bindings/python/docs/source/threads.rst14
13 files changed, 0 insertions, 582 deletions
diff --git a/bindings/python/docs/source/conf.py b/bindings/python/docs/source/conf.py
deleted file mode 100644
index bd4c8b17..00000000
--- a/bindings/python/docs/source/conf.py
+++ /dev/null
@@ -1,209 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# pyDNS documentation build configuration file, created by
-# sphinx-quickstart on Tue Feb 2 10:00:47 2010.
-#
-# This file is execfile()d with the current directory set to its containing dir.
-#
-# Note that not all possible configuration values are present in this
-# autogenerated file.
-#
-# All configuration values have a default; values that are commented out
-# serve to show the default.
-
-import sys, os
-
-from unittest.mock import Mock
-
-# If extensions (or modules to document with autodoc) are in another directory,
-# add these directories to sys.path here. If the directory is relative to the
-# documentation root, use os.path.abspath to make it absolute, like shown here.
-sys.path.insert(0,os.path.abspath('../..'))
-
-MOCK_MODULES = [
- 'ctypes',
-]
-for mod_name in MOCK_MODULES:
- sys.modules[mod_name] = Mock()
-
-
-from notmuch import __VERSION__,__AUTHOR__
-# -- General configuration -----------------------------------------------------
-
-# Add any Sphinx extension module names here, as strings. They can be extensions
-# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
-extensions = ['sphinx.ext.autodoc', 'sphinx.ext.doctest', 'sphinx.ext.intersphinx', 'sphinx.ext.todo']
-autoclass_content = "both"
-
-# Add any paths that contain templates here, relative to this directory.
-templates_path = ['_templates']
-
-# The suffix of source filenames.
-source_suffix = '.rst'
-
-# The encoding of source files.
-#source_encoding = 'utf-8'
-
-# The master toctree document.
-master_doc = 'index'
-
-# General information about the project.
-project = u'notmuch'
-copyright = u'2010-2012, ' + __AUTHOR__
-
-# The version info for the project you're documenting, acts as replacement for
-# |version| and |release|, also used in various other places throughout the
-# built documents.
-#
-# The short X.Y version.
-version = __VERSION__
-# The full version, including alpha/beta/rc tags.
-release = __VERSION__
-
-# The language for content autogenerated by Sphinx. Refer to documentation
-# for a list of supported languages.
-#language = None
-
-# There are two options for replacing |today|: either, you set today to some
-# non-false value, then it is used:
-#today = ''
-# Else, today_fmt is used as the format for a strftime call.
-#today_fmt = '%B %d, %Y'
-
-# List of documents that shouldn't be included in the build.
-#unused_docs = []
-
-# List of directories, relative to source directory, that shouldn't be searched
-# for source files.
-exclude_trees = []
-
-# The reST default role (used for this markup: `text`) to use for all documents.
-#default_role = None
-
-# If true, '()' will be appended to :func: etc. cross-reference text.
-#add_function_parentheses = True
-
-# If true, the current module name will be prepended to all description
-# unit titles (such as .. function::).
-add_module_names = False
-
-# If true, sectionauthor and moduleauthor directives will be shown in the
-# output. They are ignored by default.
-#show_authors = False
-
-# The name of the Pygments (syntax highlighting) style to use.
-pygments_style = 'sphinx'
-
-# A list of ignored prefixes for module index sorting.
-#modindex_common_prefix = []
-
-
-# -- Options for HTML output ---------------------------------------------------
-
-# The theme to use for HTML and HTML Help pages. Major themes that come with
-# Sphinx are currently 'default' and 'sphinxdoc'.
-html_theme = 'default'
-
-# Theme options are theme-specific and customize the look and feel of a theme
-# further. For a list of options available for each theme, see the
-# documentation.
-#html_theme_options = {}
-
-# Add any paths that contain custom themes here, relative to this directory.
-#html_theme_path = []
-
-# The name for this set of Sphinx documents. If None, it defaults to
-# "<project> v<release> documentation".
-#html_title = None
-
-# A shorter title for the navigation bar. Default is the same as html_title.
-#html_short_title = None
-
-# The name of an image file (relative to this directory) to place at the top
-# of the sidebar.
-#html_logo = None
-
-# The name of an image file (within the static path) to use as favicon of the
-# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
-# pixels large.
-#html_favicon = None
-
-# Add any paths that contain custom static files (such as style sheets) here,
-# relative to this directory. They are copied after the builtin static files,
-# so a file named "default.css" will overwrite the builtin "default.css".
-html_static_path = []
-
-# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
-# using the given strftime format.
-#html_last_updated_fmt = '%b %d, %Y'
-
-# If true, SmartyPants will be used to convert quotes and dashes to
-# typographically correct entities.
-#html_use_smartypants = True
-
-# Custom sidebar templates, maps document names to template names.
-#html_sidebars = {}
-
-# Additional templates that should be rendered to pages, maps page names to
-# template names.
-#html_additional_pages = {}
-
-# If false, no module index is generated.
-html_use_modindex = False
-
-# If false, no index is generated.
-#html_use_index = True
-
-# If true, the index is split into individual pages for each letter.
-#html_split_index = False
-
-# If true, links to the reST sources are added to the pages.
-#html_show_sourcelink = True
-
-# If true, an OpenSearch description file will be output, and all pages will
-# contain a <link> tag referring to it. The value of this option must be the
-# base URL from which the finished HTML is served.
-#html_use_opensearch = ''
-
-# If nonempty, this is the file name suffix for HTML files (e.g. ".xhtml").
-#html_file_suffix = ''
-
-# Output file base name for HTML help builder.
-htmlhelp_basename = 'notmuchdoc'
-
-
-# -- Options for LaTeX output --------------------------------------------------
-
-# The paper size ('letter' or 'a4').
-#latex_paper_size = 'letter'
-
-# The font size ('10pt', '11pt' or '12pt').
-#latex_font_size = '10pt'
-
-# Grouping the document tree into LaTeX files. List of tuples
-# (source start file, target name, title, author, documentclass [howto/manual]).
-latex_documents = [
- ('index', 'notmuch.tex', u'notmuch Documentation',
- u'notmuch contributors', 'manual'),
-]
-
-# The name of an image file (relative to this directory) to place at the top of
-# the title page.
-#latex_logo = None
-
-# For "manual" documents, if this is true, then toplevel headings are parts,
-# not chapters.
-#latex_use_parts = False
-
-# Additional stuff for the LaTeX preamble.
-#latex_preamble = ''
-
-# Documents to append as an appendix to all manuals.
-#latex_appendices = []
-
-# If false, no module index is generated.
-#latex_use_modindex = True
-
-
-# Example configuration for intersphinx: refer to the Python standard library.
-intersphinx_mapping = {'python': ('https://docs.python.org/3', None)}
diff --git a/bindings/python/docs/source/database.rst b/bindings/python/docs/source/database.rst
deleted file mode 100644
index 660de91d..00000000
--- a/bindings/python/docs/source/database.rst
+++ /dev/null
@@ -1,54 +0,0 @@
-:class:`Database` -- The underlying notmuch database
-====================================================
-
-.. currentmodule:: notmuch
-
-.. autoclass:: Database([path=None[, create=False[, mode=MODE.READ_ONLY]]])
-
- .. automethod:: create
-
- .. automethod:: open(path, status=MODE.READ_ONLY)
-
- .. automethod:: close
-
- .. automethod:: get_path
-
- .. automethod:: get_version
-
- .. automethod:: needs_upgrade
-
- .. automethod:: upgrade
-
- .. automethod:: begin_atomic
-
- .. automethod:: end_atomic
-
- .. automethod:: get_directory
-
- .. automethod:: index_file
-
- .. automethod:: remove_message
-
- .. automethod:: find_message
-
- .. automethod:: find_message_by_filename
-
- .. automethod:: get_all_tags
-
- .. automethod:: create_query
-
- .. automethod:: get_config
-
- .. automethod:: get_configs
-
- .. automethod:: set_config
-
- .. attribute:: Database.MODE
-
- Defines constants that are used as the mode in which to open a database.
-
- MODE.READ_ONLY
- Open the database in read-only mode
-
- MODE.READ_WRITE
- Open the database in read-write mode
diff --git a/bindings/python/docs/source/filesystem.rst b/bindings/python/docs/source/filesystem.rst
deleted file mode 100644
index 13fe1194..00000000
--- a/bindings/python/docs/source/filesystem.rst
+++ /dev/null
@@ -1,32 +0,0 @@
-Files and directories
-=====================
-
-.. currentmodule:: notmuch
-
-:class:`Filenames` -- An iterator over filenames
-------------------------------------------------
-
-.. autoclass:: Filenames
-
- .. method:: Filenames.__len__
- .. warning::
- :meth:`__len__` was removed in version 0.22 as it exhausted the
- iterator and broke list(Filenames()). Use `len(list(names))`
- instead.
-
-:class:`Directory` -- A directory entry in the database
--------------------------------------------------------
-
-.. autoclass:: Directory
-
- .. automethod:: Directory.get_child_files
-
- .. automethod:: Directory.get_child_directories
-
- .. automethod:: Directory.get_mtime
-
- .. automethod:: Directory.set_mtime
-
- .. autoattribute:: Directory.mtime
-
- .. autoattribute:: Directory.path
diff --git a/bindings/python/docs/source/index.rst b/bindings/python/docs/source/index.rst
deleted file mode 100644
index bef7e60d..00000000
--- a/bindings/python/docs/source/index.rst
+++ /dev/null
@@ -1,36 +0,0 @@
-Welcome to :mod:`notmuch`'s documentation
-=========================================
-
-.. currentmodule:: notmuch
-
-The :mod:`notmuch` module provides an interface to the `notmuch
-<https://notmuchmail.org>`_ functionality, directly interfacing to a
-shared notmuch library. Within :mod:`notmuch`, the classes
-:class:`Database`, :class:`Query` provide most of the core
-functionality, returning :class:`Threads`, :class:`Messages` and
-:class:`Tags`.
-
-.. moduleauthor:: Sebastian Spaeth <Sebastian@SSpaeth.de>
-
-:License: This module is covered under the GNU GPL v3 (or later).
-
-.. toctree::
- :maxdepth: 1
-
- quickstart
- notes
- status_and_errors
- database
- query
- messages
- message
- tags
- threads
- thread
- filesystem
-
-Indices and tables
-==================
-
-* :ref:`genindex`
-* :ref:`search`
diff --git a/bindings/python/docs/source/message.rst b/bindings/python/docs/source/message.rst
deleted file mode 100644
index b0033924..00000000
--- a/bindings/python/docs/source/message.rst
+++ /dev/null
@@ -1,54 +0,0 @@
-:class:`Message` -- A single message
-====================================
-
-.. currentmodule:: notmuch
-
-.. autoclass:: Message
-
- .. automethod:: get_message_id
-
- .. automethod:: get_thread_id
-
- .. automethod:: get_replies
-
- .. automethod:: get_filename
-
- .. automethod:: get_filenames
-
- .. attribute:: FLAG
-
- FLAG.MATCH
- This flag is automatically set by a
- Query.search_threads on those messages that match the
- query. This allows us to distinguish matches from the rest
- of the messages in that thread.
-
- .. automethod:: get_flag
-
- .. automethod:: set_flag
-
- .. automethod:: get_date
-
- .. automethod:: get_header
-
- .. automethod:: get_tags
-
- .. automethod:: get_property
-
- .. automethod:: get_properties
-
- .. automethod:: maildir_flags_to_tags
-
- .. automethod:: tags_to_maildir_flags
-
- .. automethod:: remove_tag
-
- .. automethod:: add_tag
-
- .. automethod:: remove_all_tags
-
- .. automethod:: freeze
-
- .. automethod:: thaw
-
- .. automethod:: __str__
diff --git a/bindings/python/docs/source/messages.rst b/bindings/python/docs/source/messages.rst
deleted file mode 100644
index 3ccf505c..00000000
--- a/bindings/python/docs/source/messages.rst
+++ /dev/null
@@ -1,15 +0,0 @@
-:class:`Messages` -- A bunch of messages
-========================================
-
-.. currentmodule:: notmuch
-
-.. autoclass:: Messages
-
- .. automethod:: collect_tags
-
- .. method:: __len__()
-
- .. warning::
-
- :meth:`__len__` was removed in version 0.6 as it exhausted the iterator and broke
- list(Messages()). Use the :meth:`Query.count_messages` function or use `len(list(msgs))`.
diff --git a/bindings/python/docs/source/notes.rst b/bindings/python/docs/source/notes.rst
deleted file mode 100644
index a7927485..00000000
--- a/bindings/python/docs/source/notes.rst
+++ /dev/null
@@ -1,6 +0,0 @@
-Interfacing with notmuch
-========================
-
-.. todo:: move the note about talloc out of the code
-
-.. automodule:: notmuch
diff --git a/bindings/python/docs/source/query.rst b/bindings/python/docs/source/query.rst
deleted file mode 100644
index 785e984b..00000000
--- a/bindings/python/docs/source/query.rst
+++ /dev/null
@@ -1,43 +0,0 @@
-:class:`Query` -- A search query
-================================
-
-.. currentmodule:: notmuch
-
-.. autoclass:: Query
-
- .. automethod:: create
-
- .. attribute:: Query.SORT
-
- Defines constants that are used as the mode in which to open a database.
-
- SORT.OLDEST_FIRST
- Sort by message date, oldest first.
-
- SORT.NEWEST_FIRST
- Sort by message date, newest first.
-
- SORT.MESSAGE_ID
- Sort by email message ID.
-
- SORT.UNSORTED
- Do not apply a special sort order (returns results in document id
- order).
-
- .. automethod:: set_sort
-
- .. attribute:: sort
-
- Instance attribute :attr:`sort` contains the sort order (see
- :attr:`Query.SORT`) if explicitly specified via
- :meth:`set_sort`. By default it is set to `None`.
-
- .. automethod:: exclude_tag
-
- .. automethod:: search_threads
-
- .. automethod:: search_messages
-
- .. automethod:: count_messages
-
- .. automethod:: count_threads
diff --git a/bindings/python/docs/source/quickstart.rst b/bindings/python/docs/source/quickstart.rst
deleted file mode 100644
index 609f42e1..00000000
--- a/bindings/python/docs/source/quickstart.rst
+++ /dev/null
@@ -1,19 +0,0 @@
-Quickstart and examples
-=======================
-
-.. todo:: write a nice introduction
-.. todo:: improve the examples
-
-Notmuch can be imported as::
-
- import notmuch
-
-or::
-
- from notmuch import Query, Database
-
- db = Database('path', create=True)
- msgs = Query(db, 'from:myself').search_messages()
-
- for msg in msgs:
- print(msg)
diff --git a/bindings/python/docs/source/status_and_errors.rst b/bindings/python/docs/source/status_and_errors.rst
deleted file mode 100644
index 68913f16..00000000
--- a/bindings/python/docs/source/status_and_errors.rst
+++ /dev/null
@@ -1,57 +0,0 @@
-.. currentmodule:: notmuch
-
-Status and Errors
-=================
-
-Some methods return a status, indicating if an operation was successful and what the error was. Most of these status codes are expressed as a specific value, the :class:`notmuch.STATUS`.
-
-.. note::
-
- Prior to version 0.12 the exception classes and the enumeration
- :class:`notmuch.STATUS` were defined in `notmuch.globals`. They
- have since then been moved into `notmuch.errors`.
-
-:class:`STATUS` -- Notmuch operation return value
---------------------------------------------------
-
-.. autoclass:: notmuch.STATUS
- :inherited-members:
-
-.. automethod:: notmuch.STATUS.status2str
-
-:exc:`NotmuchError` -- A Notmuch execution error
-------------------------------------------------
-Whenever an error occurs, we throw a special Exception :exc:`NotmuchError`, or a more fine grained Exception which is derived from it. This means it is always safe to check for NotmuchErrors if you want to catch all errors. If you are interested in more fine grained exceptions, you can use those below.
-
-.. autoexception:: NotmuchError
-
-The following exceptions are all directly derived from NotmuchError. Each of them corresponds to a specific :class:`notmuch.STATUS` value. You can either check the :attr:`status` attribute of a NotmuchError to see if a specific error has occurred, or you can directly check for the following Exception types:
-
-.. autoexception:: OutOfMemoryError(message=None)
- :members:
-.. autoexception:: ReadOnlyDatabaseError(message=None)
- :members:
-.. autoexception:: XapianError(message=None)
- :members:
-.. autoexception:: FileError(message=None)
- :members:
-.. autoexception:: FileNotEmailError(message=None)
- :members:
-.. autoexception:: DuplicateMessageIdError(message=None)
- :members:
-.. autoexception:: NullPointerError(message=None)
- :members:
-.. autoexception:: TagTooLongError(message=None)
- :members:
-.. autoexception:: UnbalancedFreezeThawError(message=None)
- :members:
-.. autoexception:: UnbalancedAtomicError(message=None)
- :members:
-.. autoexception:: UnsupportedOperationError(message=None)
- :members:
-.. autoexception:: UpgradeRequiredError(message=None)
- :members:
-.. autoexception:: PathError(message=None)
- :members:
-.. autoexception:: NotInitializedError(message=None)
- :members:
diff --git a/bindings/python/docs/source/tags.rst b/bindings/python/docs/source/tags.rst
deleted file mode 100644
index 31527d4b..00000000
--- a/bindings/python/docs/source/tags.rst
+++ /dev/null
@@ -1,17 +0,0 @@
-:class:`Tags` -- Notmuch tags
------------------------------
-
-.. currentmodule:: notmuch
-
-.. autoclass:: Tags
- :members:
-
- .. method:: __len__
-
- .. warning::
-
- :meth:`__len__` was removed in version 0.6 as it exhausted the iterator and broke
- list(Tags()). Use :meth:`len(list(msgs))` instead if you need to know the number of
- tags.
-
- .. automethod:: __str__
diff --git a/bindings/python/docs/source/thread.rst b/bindings/python/docs/source/thread.rst
deleted file mode 100644
index 40678725..00000000
--- a/bindings/python/docs/source/thread.rst
+++ /dev/null
@@ -1,26 +0,0 @@
-:class:`Thread` -- A single thread
-==================================
-
-.. currentmodule:: notmuch
-
-.. autoclass:: Thread
-
- .. automethod:: get_thread_id
-
- .. automethod:: get_total_messages
-
- .. automethod:: get_toplevel_messages
-
- .. automethod:: get_matched_messages
-
- .. automethod:: get_authors
-
- .. automethod:: get_subject
-
- .. automethod:: get_oldest_date
-
- .. automethod:: get_newest_date
-
- .. automethod:: get_tags
-
- .. automethod:: __str__
diff --git a/bindings/python/docs/source/threads.rst b/bindings/python/docs/source/threads.rst
deleted file mode 100644
index 46ce5be5..00000000
--- a/bindings/python/docs/source/threads.rst
+++ /dev/null
@@ -1,14 +0,0 @@
-:class:`Threads` -- Threads iterator
-====================================
-
-.. currentmodule:: notmuch
-
-.. autoclass:: Threads
-
- .. method:: __len__
- .. warning::
- :meth:`__len__` was removed in version 0.22 as it exhausted the
- iterator and broke list(Threads()). Use `len(list(msgs))`
- instead.
-
- .. automethod:: __str__