From 409af92a1ac36f3b57bf39afbb7fc9ce82c0bbb2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Bidoul?= Date: Sat, 16 Nov 2024 13:40:48 +0100 Subject: [PATCH] Fix gevent and greenlet build issue The gevent and greelet versions pinned in Odoo's requirements.txt don't build anymore with the latest cython, so we use the latest versions which have wheels. --- Dockerfile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index c687950..9779876 100644 --- a/Dockerfile +++ b/Dockerfile @@ -111,7 +111,12 @@ ARG odoo_version # Install Odoo requirements (use ADD for correct layer caching). # We use requirements from OCB for easier maintenance of older versions. ADD https://raw.githubusercontent.com/OCA/OCB/$odoo_version/requirements.txt /tmp/ocb-requirements.txt -RUN pip install --no-cache-dir \ +# The sed command is to use the latest version of gevent and greenlet. The +# latest version works with all versions of Odoo that we support here, and the +# oldest pinned in Odoo's requirements.txt don't have wheels, and don't build +# anymore with the latest cython. +RUN sed -i -E "s/^(gevent|greenlet)==.*/\1/" requirements.txt \ + && pip install --no-cache-dir \ -r /tmp/ocb-requirements.txt \ packaging