From f0879d680a2e7ccce312778dbced83ae65d1ae5d Mon Sep 17 00:00:00 2001 From: Nicolas MASSART Date: Thu, 16 May 2019 13:14:31 +0200 Subject: [PATCH] add RTD config file to fix Python version issue (#1453) Signed-off-by: Adrian Sutton --- Jenkinsfile | 4 +++- readthedocs.yml | 17 +++++++++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 readthedocs.yml diff --git a/Jenkinsfile b/Jenkinsfile index 5031f7c98e..cf5f8a9fe3 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -161,7 +161,9 @@ try { node { checkout scm stage(stage_name + 'Build') { - def container = docker.image("python:3-alpine").inside() { +// Python image version should be set to the same as in readthedocs.yml +// to make sure we test with the same version that RTD will use + def container = docker.image("python:3.7-alpine").inside() { try { sh 'pip install -r docs/requirements.txt' sh 'mkdocs build -s' diff --git a/readthedocs.yml b/readthedocs.yml new file mode 100644 index 0000000000..4d42d61f20 --- /dev/null +++ b/readthedocs.yml @@ -0,0 +1,17 @@ +# readthedocs.yml + +version: 2 + +build: + image: latest + +python: +# Python version should be set to this one too in the Jenkinsfile to +# make sure we test with the same version that RTD will use + version: 3.7 + install: + - requirements: docs/requirements.txt + +mkdocs: + configuration: mkdocs.yml + fail_on_warning: false