-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create, publish public API documentation on readthedocs.io (#98)
This documents a minimal public API for records-mover at https://records-mover.readthedocs.io/en/publish_docs/
- Loading branch information
1 parent
f5828e9
commit 3312802
Showing
44 changed files
with
860 additions
and
230 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# .readthedocs.yml | ||
# Read the Docs configuration file | ||
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details | ||
|
||
# Required | ||
version: 2 | ||
|
||
python: | ||
version: 3.7 | ||
install: | ||
- method: pip | ||
path: . | ||
extra_requirements: | ||
- docs | ||
|
||
sphinx: | ||
fail_on_warning: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Minimal makefile for Sphinx documentation | ||
# | ||
|
||
# You can set these variables from the command line, and also | ||
# from the environment for the first two. | ||
SPHINXOPTS ?= -W | ||
SPHINXBUILD ?= sphinx-build | ||
SOURCEDIR = source | ||
BUILDDIR = build | ||
|
||
# Put it first so that "make" without argument is like "make help". | ||
help: | ||
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) | ||
|
||
apidocs: | ||
@sphinx-apidoc -o ./source ../records_mover | ||
|
||
.PHONY: help Makefile | ||
|
||
# Catch-all target: route all unknown targets to Sphinx using the new | ||
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). | ||
%: Makefile | ||
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
# Configuration file for the Sphinx documentation builder. | ||
# | ||
# This file only contains a selection of the most common options. For a full | ||
# list see the documentation: | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html | ||
|
||
# -- Path setup -------------------------------------------------------------- | ||
|
||
# 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. | ||
# | ||
import os | ||
import sys | ||
sys.path.insert(0, os.path.abspath('../..')) | ||
import records_mover # noqa | ||
|
||
|
||
# -- Project information ----------------------------------------------------- | ||
|
||
project = 'records-mover' | ||
copyright = '2020 BlueLabs Analytics, Inc.' | ||
author = 'Vince Broz' | ||
|
||
# The full version, including alpha/beta/rc tags | ||
release = records_mover.version.__version__ | ||
|
||
|
||
# -- 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', | ||
] | ||
|
||
# Add any paths that contain templates here, relative to this directory. | ||
templates_path = ['_templates'] | ||
|
||
# List of patterns, relative to source directory, that match files and | ||
# directories to ignore when looking for source files. | ||
# This pattern also affects html_static_path and html_extra_path. | ||
exclude_patterns = [] | ||
|
||
# | ||
# This value selects if automatically documented members are sorted | ||
# alphabetical (value 'alphabetical'), by member type (value | ||
# 'groupwise') or by source order (value 'bysource'). The default is | ||
# alphabetical. | ||
# | ||
# records mover picks 'bysource' so that enums appear in the order | ||
# listed in the source code, which can reflect a natural order. | ||
# | ||
autodoc_member_order = 'bysource' | ||
|
||
# -- Options for HTML output ------------------------------------------------- | ||
|
||
# The theme to use for HTML and HTML Help pages. See the documentation for | ||
# a list of builtin themes. | ||
# | ||
html_theme = 'sphinx_rtd_theme' | ||
|
||
# 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 = ['_static'] | ||
|
||
# -- Options for type generation --------------------------------------------- | ||
|
||
# | ||
# Document parameter types in description of parameter, not in | ||
# function signature part of documentation. | ||
# | ||
autodoc_typehints = 'description' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
.. records-mover documentation master file, created by | ||
sphinx-quickstart on Fri Jun 26 11:46:58 2020. | ||
You can adapt this file completely to your liking, but it should at least | ||
contain the root `toctree` directive. | ||
Welcome to records-mover's documentation! | ||
========================================= | ||
|
||
.. toctree:: | ||
:maxdepth: 2 | ||
:caption: Contents: | ||
|
||
records_mover | ||
|
||
|
||
Indices and tables | ||
================== | ||
|
||
* :ref:`genindex` | ||
* :ref:`modindex` | ||
* :ref:`search` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
records\_mover.airflow.hooks package | ||
==================================== | ||
|
||
Module contents | ||
--------------- | ||
|
||
.. comment: | ||
SqlAlchemyDbHook.validate_and_prepare_target_directory is something | ||
I'd like to explore removing and promoting to something | ||
non-Airflow-related, so let's not include a docstring for it and leave | ||
':undoc-members:' out of the config below. | ||
.. automodule:: records_mover.airflow.hooks | ||
:members: | ||
:show-inheritance: | ||
:special-members: __init__ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
records\_mover.airflow package | ||
============================== | ||
|
||
Subpackages | ||
----------- | ||
|
||
.. toctree:: | ||
:maxdepth: 4 | ||
|
||
records_mover.airflow.hooks |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
records\_mover.records package | ||
============================== | ||
|
||
Subpackages | ||
----------- | ||
|
||
.. toctree:: | ||
:maxdepth: 4 | ||
|
||
records_mover.records.sources | ||
records_mover.records.targets | ||
|
||
Submodules | ||
---------- | ||
|
||
records\_mover.records.base\_records\_format module | ||
--------------------------------------------------- | ||
|
||
.. autoclass:: records_mover.records.base_records_format.BaseRecordsFormat | ||
:members: | ||
:show-inheritance: | ||
:special-members: __init__ | ||
|
||
Module contents | ||
--------------- | ||
|
||
.. comment: | ||
I exclude PartialRecordsHints entirely below because Sphinx doesn't | ||
yet support TypedDict types that have hyphens as part of the keys. | ||
Example error on 'make html': | ||
WARNING: invalid signature for autoinstanceattribute | ||
('records_mover.records::PartialRecordsHints.header-row') | ||
I exclude RecordsSchema as we haven't defined yet exactly what | ||
public API to export. | ||
https://github.com/bluelabsio/records-mover/issues/97 | ||
I exclude RecordsFormat as it's generally an internal factory | ||
method useful when reading undifferentiated JSON files - a general | ||
user ought to be able to select their records format in advance and | ||
use the correct subclass. | ||
I exclude UntypedRecordsHints and RecordsFormatType as it hasn't | ||
been used in any other part of the public interface. | ||
I exclude DelimitedVariant as there's no way to specify a | ||
docstring, so I add out-of-band documentation below. | ||
.. automodule:: records_mover.records | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:exclude-members: DelimitedRecordsFormat, ParquetRecordsFormat, ProcessingInstructions, PartialRecordsHints, RecordsSchema, RecordsFormat, UntypedRecordsHints, RecordsFormatType, DelimitedVariant | ||
|
||
.. autoclass:: records_mover.records.DelimitedRecordsFormat | ||
:undoc-members: | ||
:show-inheritance: | ||
:special-members: __init__ | ||
|
||
.. autoclass:: records_mover.records.ParquetRecordsFormat | ||
:undoc-members: | ||
:show-inheritance: | ||
:special-members: __init__ | ||
|
||
.. autoclass:: records_mover.records.ProcessingInstructions | ||
:undoc-members: | ||
:show-inheritance: | ||
:special-members: __init__ | ||
|
||
.. py:data:: DelimitedVariant | ||
:module: records_mover.records | ||
|
||
Valid string values for the variant of a delimited records format. | ||
Variants specify a default set of parsing hints for how the delimited | ||
file is formatted. See the `records format specification | ||
<https://github.com/bluelabsio/records-mover/blob/master/docs/RECORDS_SPEC.md>`_ | ||
for semantics of each. | ||
|
||
alias of Literal[dumb, csv, bigquery, bluelabs, vertica] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
records\_mover.records.sources package | ||
====================================== | ||
|
||
Module contents | ||
--------------- | ||
|
||
.. automodule:: records_mover.records.sources | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
records\_mover.records.targets package | ||
====================================== | ||
|
||
Module contents | ||
--------------- | ||
|
||
.. automodule:: records_mover.records.targets | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
records\_mover package | ||
====================== | ||
|
||
Subpackages | ||
----------- | ||
|
||
.. toctree:: | ||
:maxdepth: 4 | ||
|
||
records_mover.airflow | ||
records_mover.records | ||
|
||
Module contents | ||
--------------- | ||
|
||
.. automodule:: records_mover | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:exclude-members: Session | ||
|
||
.. autoclass:: records_mover.Session | ||
:members: records, set_stream_logging, get_db_engine, get_default_db_engine | ||
:undoc-members: | ||
:show-inheritance: | ||
:special-members: __init__ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
1002 | ||
1019 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
93.700 | ||
93.7100 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
174 | ||
170 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
92.2800 | ||
92.3100 |
File renamed without changes.
Oops, something went wrong.