| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
Add Read the Docs configuration file for documentation build
Added configuration settings for Sphinx documentation. Direct copy from example conf file.
Updated project information to load from pyproject.toml.
- Add docs optional-dependencies group (sphinx, tomli) to pyproject.toml - Wire up .readthedocs.yaml to install .[docs] extra - Fix conf.py: correct pyproject.toml path, use importlib.metadata for version, switch to alabaster theme, use tomllib/tomli compat import - Add minimal docs/index.rst - Fix RST docstring errors in connection_item, site_item, job_item, task_item that caused Sphinx build warnings/errors Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
On push to master, builds Sphinx HTML and opens a PR from docs-update into gh-pages so the generated API reference can be reviewed before going live. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sorry, something went wrong.
Four cleanups on the docs branch surfaced by an adversarial review:
- Revert id_ -> id docstring renames in JobItem and TaskItem. The
constructors take `id_` (trailing underscore because `id` shadows the
builtin); the docstring should describe the actual parameter name.
The original rename was cosmetic and made the docstring actively
misleading — users copying the docstring's kwarg would get a
TypeError.
- Add :imported-members: to docs/index.rst. Without it, the top-level
automodule directive only documents symbols defined in
tableauserverclient/__init__.py itself (which is 99% re-exports), so
the generated API reference was nearly empty. With this, all
re-exported classes render.
- Pin [docs] extras. Was `sphinx`, `tomli`, `furo` — unpinned. Now
`sphinx>=7,<9`, `furo>=2024,<2027`, `tomli; python_version < '3.11'`.
A future Sphinx major bump can silently break the RTD reproducible
build otherwise. `tomli` narrowed to just the Python 3.10 build path;
3.11+ has stdlib tomllib.
- Workflow changes:
- Add `concurrency: docs-publish` so overlapping runs don't rewrite
docs-update mid-flight.
- Set `delete-branch: true` on peter-evans/create-pull-request so
stale docs-update branches don't accumulate and force-updates
don't strand review comments.
- Set `fetch-depth: 0` on the gh-pages checkout so
create-pull-request can detect no-op diffs correctly.
- Remove the templates_path = ["_templates"] config in docs/conf.py.
The referenced directory doesn't ship, so Sphinx emits a warning on
every build.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Adds a Sphinx/Read the Docs documentation pipeline to generate an API reference from docstrings, intended to live alongside (and eventually replace) the manually maintained api-ref.md on gh-pages.
Changes:
Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.
Show a summary per file| File | Description |
|---|---|
| .readthedocs.yaml | Adds RTD build/install configuration for Sphinx docs. |
| docs/conf.py | Adds Sphinx configuration (theme/extensions) and reads project metadata from pyproject.toml. |
| docs/index.rst | Adds Sphinx root page that auto-documents tableauserverclient (including re-exports). |
| .github/workflows/docs.yml | Adds CI job to build Sphinx HTML and open a PR to gh-pages with generated output. |
| pyproject.toml | Adds docs extras (Sphinx, furo, tomli fallback). |
| tableauserverclient/models/connection_item.py | Refines docstring for XML parsing helper. |
| tableauserverclient/models/site_item.py | Clarifies tier capacity docstrings for Creator/Explorer/Viewer. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Sorry, something went wrong.
| .. toctree:: | ||
| :maxdepth: 2 | ||
| :caption: Contents: | ||
|
|
The previous conf.py used a single `.. automodule:: tableauserverclient` which only covers names re-exported from `tableauserverclient/__init__.py`. That silently drops every endpoint class and every root helper module -- Favorites, VirtualConnections, config, datetime_helpers, filesys_helpers, namespace, exponential_backoff -- and readers running into missing methods had no way to find the underlying signatures. Wire in sphinx-autoapi with autoapi_dirs pointing at the source tree. The generator walks every module (including private endpoints) and produces a reference page per module under docs/reference/. `autoapi_root` and the corresponding .gitignore entry are kept in sync. Other tweaks: - Replace the empty toctree in docs/index.rst with a hidden one so autoapi's `autoapi_add_toctree_entry` has a node to append to (without an existing toctree it is a no-op and Furo's sidebar comes out empty). - Add `python -m pip install --upgrade pip` to the docs workflow to avoid the resolver-warnings that older pips emit on modern extras. Docstring warnings surfaced by autoapi are not addressed here; a follow-up PR will fix the RST-vs-Google mismatches introduced by the recent Favorites, VirtualConnections, and root-helper docstring passes. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
| Back | FazBrowse Home | New Git URL |
Motivation
api-ref.md on gh-pages is the canonical reference doc today. It's
hand-edited: when a new method or model field lands, someone has to
remember to update it. Coverage drifts and diverges from the code.
Sphinx generates the same content from docstrings, so the update path
becomes "write the docstring, docs regenerate." Concepts and tutorials
stay in Jekyll -- Sphinx just replaces the reference section.
Not merging this into the live Jekyll site yet: docstring coverage
across the models package is thin, and the auto-generated output today
would be a regression from the handwritten api-ref.md. Landing the
pipeline now unblocks incremental docstring work without a public-facing
rush. #1855 is the first tranche of docstring backfill.
Behavior change
None to the runtime library. Adds a docs build pipeline:
so re-exports from __init__.py render (without :imported-members:
the output was nearly empty)
builds Sphinx, opens a PR into gh-pages at sphinx/. Uses
concurrency: docs-publish to serialize runs
Also incidentally: small docstring cleanups in connection_item.py and
site_item.py (side effect of the initial Sphinx pass).
Why both RTD and gh-pages/sphinx: the workflow-driven PR into gh-pages
puts the built HTML next to the existing Jekyll site so we can add nav
links whenever coverage is good enough. RTD is the fallback/canonical
hosting if we prefer to keep gh-pages Jekyll-only. Long-term one goes
away; keeping both live in the setup lets us pick without rebuilding.
Test plan
(sphinx-build -b html docs sphinx_build) -- 3000-line index with all
re-exports rendering. One benign warning about a duplicate
UserItem.idp_configuration_id object description (pre-existing
property+setter shape).
the PR merges and RTD picks up the config
on master
🤖 Generated with Claude Code