Skip to content
This repository was archived by the owner on Feb 13, 2026. It is now read-only.

Commit cef8fba

Browse files
authored
chore: use Python 3.8 for docs / docfx sessions (#125)
Works around recent changes to the Kokoro 'docs-presubmt' configuration. See: googleapis/python-api-core#224 Also, pin sphinx version (`docs` / `docfx`) and use 'gcp-sphinx-docfx-yaml' (`docfx`).
1 parent f6584bc commit cef8fba

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

noxfile.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -106,13 +106,13 @@ def cover(session):
106106
session.run("coverage", "erase")
107107

108108

109-
@nox.session(python=DEFAULT_PYTHON_VERSION)
109+
@nox.session(python="3.8")
110110
def docs(session):
111111
"""Build the docs for this library."""
112112

113113
session.install(".", "grpcio >= 1.8.2", "grpcio-gcp >= 0.2.2")
114114
session.install("-e", ".")
115-
session.install("sphinx", "alabaster", "recommonmark")
115+
session.install("sphinx==4.0.1", "alabaster", "recommonmark")
116116

117117
shutil.rmtree(os.path.join("docs", "_build"), ignore_errors=True)
118118
session.run(
@@ -129,12 +129,14 @@ def docs(session):
129129
)
130130

131131

132-
@nox.session(python=DEFAULT_PYTHON_VERSION)
132+
@nox.session(python="3.8")
133133
def docfx(session):
134134
"""Build the docfx yaml files for this library."""
135135

136136
session.install("-e", ".")
137-
session.install("sphinx", "alabaster", "recommonmark", "sphinx-docfx-yaml")
137+
session.install(
138+
"sphinx==4.0.1", "alabaster", "recommonmark", "gcp-sphinx-docfx-yaml",
139+
)
138140

139141
shutil.rmtree(os.path.join("docs", "_build"), ignore_errors=True)
140142
session.run(

0 commit comments

Comments
 (0)