Skip to content

Commit e962dee

Browse files
authored
ci(v1): fix builds in v1 branch (#610)
* fix docs build * pin flake8 * remove pin for pytest * use pytest instead of py.test
1 parent 3164409 commit e962dee

File tree

1 file changed

+29
-7
lines changed

1 file changed

+29
-7
lines changed

noxfile.py

Lines changed: 29 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ def lint(session):
6161
Returns a failure if the linters find linting errors or sufficiently
6262
serious code quality issues.
6363
"""
64-
session.install("flake8", BLACK_VERSION)
64+
session.install("flake8==6.0.0", BLACK_VERSION)
6565
session.install(".")
6666
session.run(
6767
"black",
@@ -97,9 +97,7 @@ def default(session, install_grpc=True):
9797
session.install(
9898
"dataclasses",
9999
"mock",
100-
# Revert to just "pytest" once
101-
# https://github.com/pytest-dev/pytest/issues/10451 is fixed
102-
"pytest<7.2.0",
100+
"pytest",
103101
"pytest-cov",
104102
"pytest-xdist",
105103
)
@@ -112,7 +110,7 @@ def default(session, install_grpc=True):
112110
pytest_args = [
113111
"python",
114112
"-m",
115-
"py.test",
113+
"pytest",
116114
*(
117115
# Helpful for running a single test or testfile.
118116
session.posargs
@@ -217,7 +215,20 @@ def docs(session):
217215
"""Build the docs for this library."""
218216

219217
session.install("-e", ".[grpc]")
220-
session.install("sphinx==4.2.0", "alabaster", "recommonmark")
218+
session.install(
219+
# We need to pin to specific versions of the `sphinxcontrib-*` packages
220+
# which still support sphinx 4.x.
221+
# See https://github.com/googleapis/sphinx-docfx-yaml/issues/344
222+
# and https://github.com/googleapis/sphinx-docfx-yaml/issues/345.
223+
"sphinxcontrib-applehelp==1.0.4",
224+
"sphinxcontrib-devhelp==1.0.2",
225+
"sphinxcontrib-htmlhelp==2.0.1",
226+
"sphinxcontrib-qthelp==1.0.3",
227+
"sphinxcontrib-serializinghtml==1.1.5",
228+
"sphinx==4.5.0",
229+
"alabaster",
230+
"recommonmark",
231+
)
221232

222233
shutil.rmtree(os.path.join("docs", "_build"), ignore_errors=True)
223234
session.run(
@@ -240,7 +251,18 @@ def docfx(session):
240251

241252
session.install("-e", ".")
242253
session.install(
243-
"sphinx==4.0.1", "alabaster", "recommonmark", "gcp-sphinx-docfx-yaml"
254+
# We need to pin to specific versions of the `sphinxcontrib-*` packages
255+
# which still support sphinx 4.x.
256+
# See https://github.com/googleapis/sphinx-docfx-yaml/issues/344
257+
# and https://github.com/googleapis/sphinx-docfx-yaml/issues/345.
258+
"sphinxcontrib-applehelp==1.0.4",
259+
"sphinxcontrib-devhelp==1.0.2",
260+
"sphinxcontrib-htmlhelp==2.0.1",
261+
"sphinxcontrib-qthelp==1.0.3",
262+
"sphinxcontrib-serializinghtml==1.1.5",
263+
"gcp-sphinx-docfx-yaml",
264+
"alabaster",
265+
"recommonmark",
244266
)
245267

246268
shutil.rmtree(os.path.join("docs", "_build"), ignore_errors=True)

0 commit comments

Comments
 (0)