Skip to content

Commit e51f803

Browse files
[deps][ci] Creating depset for docs & updating pydantic doc ver (#57947)
creating a depset for doc builds Pinning pydantic==2.50 for doc requirements due to api_policy_check failing due to dependencies (failure below) Installing ray without deps Failure due to dependencies: https://buildkite.com/ray-project/premerge/builds/52231#019a04a9-e9f8-4151-b5e5-d4bceb48a3cc Successful api_policy_check run on this PR: https://buildkite.com/ray-project/microcheck/builds/29312#019a05b8-ef40-4449-9ca2-6dd9d8e790a7 --------- Signed-off-by: elliot-barn <[email protected]> Co-authored-by: Lonnie Liu <[email protected]>
1 parent 37386b7 commit e51f803

File tree

11 files changed

+4593
-12
lines changed

11 files changed

+4593
-12
lines changed

.buildkite/base.rayci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@ steps:
8686
- "3.12"
8787
env:
8888
PYTHON: "{{matrix}}"
89+
REQUIREMENTS_FILE: "python/deplocks/docs/docbuild_depset_py{{matrix}}.lock"
8990
tags: cibase
9091

9192
- name: docgpubuild

.buildkite/dependencies.rayci.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,3 +47,12 @@ steps:
4747
- bazel run //ci/raydepsets:raydepsets -- build ci/raydepsets/configs/release_multimodal_inference_benchmarks_tests.depsets.yaml --check
4848
job_env: manylinux
4949
depends_on: manylinux
50+
51+
- label: ":tapioca: build: raydepsets: compile doc dependencies"
52+
key: raydepsets_compile_doc_dependencies
53+
tags: always
54+
instance_type: medium
55+
commands:
56+
- bazel run //ci/raydepsets:raydepsets -- build ci/raydepsets/configs/docs.depsets.yaml --check
57+
job_env: manylinux
58+
depends_on: manylinux

.readthedocs.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,4 +20,4 @@ sphinx:
2020
# https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
2121
python:
2222
install:
23-
- requirements: doc/requirements-doc.txt
23+
- requirements: python/deplocks/docs/docbuild_depset_py3.12.lock

ci/docker/doc.build.Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ FROM $DOCKER_IMAGE_RAY_DASHBOARD AS ray_dashboard
77

88
FROM $DOCKER_IMAGE_BASE_BUILD
99

10-
SHELL ["/bin/bash", "-ice"]
11-
1210
COPY . .
1311

12+
SHELL ["/bin/bash", "-ice"]
13+
1414
RUN --mount=type=bind,from=ray_core,target=/mnt/ray-core \
1515
--mount=type=bind,from=ray_dashboard,target=/mnt/ray-dashboard \
1616
<<EOF
@@ -24,6 +24,6 @@ cp /mnt/ray-core/ray_pkg.zip /opt/ray-build/ray_pkg.zip
2424
cp /mnt/ray-core/ray_py_proto.zip /opt/ray-build/ray_py_proto.zip
2525
cp /mnt/ray-dashboard/dashboard.tar.gz /opt/ray-build/dashboard.tar.gz
2626

27-
pip install -r doc/requirements-doc.txt
27+
pip install -r python/deplocks/docs/docbuild_depset_py${PYTHON}.lock
2828

2929
EOF

ci/docker/doc.build.wanda.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ froms:
55
- cr.ray.io/rayproject/ray-dashboard
66
dockerfile: ci/docker/doc.build.Dockerfile
77
srcs:
8-
- doc/requirements-doc.txt
8+
- $REQUIREMENTS_FILE
99
build_args:
1010
- DOCKER_IMAGE_BASE_BUILD=cr.ray.io/rayproject/oss-ci-base_build-py$PYTHON
1111
- DOCKER_IMAGE_RAY_CORE=cr.ray.io/rayproject/ray-core-py$PYTHON

ci/lint/lint.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -104,21 +104,21 @@ test_coverage() {
104104
python ci/pipeline/check-test-run.py
105105
}
106106

107-
_install_ray() {
107+
_install_ray_no_deps() {
108108
if [[ -d /opt/ray-build ]]; then
109109
unzip -o -q /opt/ray-build/ray_pkg.zip -d python
110110
unzip -o -q /opt/ray-build/ray_py_proto.zip -d python
111111
mkdir -p python/ray/dashboard/client/build
112112
tar -xzf /opt/ray-build/dashboard.tar.gz -C python/ray/dashboard/client/build
113-
SKIP_BAZEL_BUILD=1 pip install -e "python[all]"
113+
SKIP_BAZEL_BUILD=1 pip install -e "python[all]" --no-deps
114114
else
115-
RAY_DISABLE_EXTRA_CPP=1 pip install -e "python[all]"
115+
RAY_DISABLE_EXTRA_CPP=1 pip install -e "python[all]" --no-deps
116116
fi
117117
}
118118

119119
api_annotations() {
120120
echo "--- Install Ray"
121-
_install_ray
121+
_install_ray_no_deps
122122

123123
echo "--- Check API annotations"
124124
./ci/lint/check_api_annotations.py
@@ -130,7 +130,7 @@ api_policy_check() {
130130
make -C doc/ html
131131

132132
echo "--- Install Ray"
133-
_install_ray
133+
_install_ray_no_deps
134134

135135
echo "--- Check API/doc consistency"
136136
bazel run //ci/ray_ci/doc:cmd_check_api_discrepancy -- /ray "$@"
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
build_arg_sets:
2+
py39:
3+
PYTHON_VERSION: "3.9"
4+
PYTHON_SHORT: "39"
5+
py310:
6+
PYTHON_VERSION: "3.10"
7+
PYTHON_SHORT: "310"
8+
py312:
9+
PYTHON_VERSION: "3.12"
10+
PYTHON_SHORT: "312"
11+
12+
13+
depsets:
14+
- name: docbuild_depset_${PYTHON_SHORT}
15+
operation: compile
16+
depsets:
17+
- ray_img_depset_${PYTHON_SHORT}
18+
requirements:
19+
- doc/requirements-doc.txt
20+
output: python/deplocks/docs/docbuild_depset_py${PYTHON_VERSION}.lock
21+
append_flags:
22+
- --python-version=${PYTHON_VERSION}
23+
- --python-platform=linux
24+
- --unsafe-package ray
25+
build_arg_sets:
26+
- py39
27+
- py310
28+
- py312

doc/requirements-doc.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,11 @@ autodoc_pydantic==2.2.0
2222
appnope
2323
sphinx-docsearch==0.0.7
2424

25-
pydantic!=2.0.*,!=2.1.*,!=2.2.*,!=2.3.*,!=2.4.*,<3
25+
pydantic==2.5.0
2626

2727
# MyST
2828
myst-parser==2.0.0 # Needed to parse markdown
2929
myst-nb==1.0.0rc0 # Most recent version of myst-nb; pin when new release is made
30-
3130
# Jupyter conversion
3231
jupytext==1.15.2
3332

python/deplocks/docs/docbuild_depset_py3.10.lock

Lines changed: 1530 additions & 0 deletions
Large diffs are not rendered by default.

python/deplocks/docs/docbuild_depset_py3.12.lock

Lines changed: 1482 additions & 0 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)