You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to install clipspy on an alpine-based docker image (see Dockerfile below), I get an error (see below). I have been able to install clips on alpine without clipspy using make release and CLIPS's makefile (see last docker file below).
I'd be happy to try and help making clipspy installable on alpine as well, as this is a popular docker image for running python. I'd just be happy to get some help understanding why clipspy is building CLIPS as it does.
Dockerfile for installing clipspy:
FROM python:3.12-alpine
RUN apk add build-base curl make
RUN pip install clipspy
CMD ["python", "-c", "'from clips import __version__; print(__version__)'"]
Error when running the above:
[+] Building 17.7s (6/6) FINISHED docker:default
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 198B 0.0s
=> [internal] load metadata for docker.io/library/python:3.12-alpine 0.0s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 2B 0.0s
=> [1/3] FROM docker.io/library/python:3.12-alpine 0.0s
=> CACHED [2/3] RUN apk add build-base curl make 0.0s
=> ERROR [3/3] RUN pip install clipspy 17.6s
------
> [3/3] RUN pip install clipspy:
4.022 Collecting clipspy
4.268 Downloading clipspy-1.0.4.tar.gz (28 kB)
4.320 Installing build dependencies: started
10.70 Installing build dependencies: finished with status 'done'
10.70 Getting requirements to build wheel: started
11.06 Getting requirements to build wheel: finished with status 'done'
11.06 Installing backend dependencies: started
14.95 Installing backend dependencies: finished with status 'done'
14.95 Preparing metadata (pyproject.toml): started
15.45 Preparing metadata (pyproject.toml): finished with status 'done'
15.71 Collecting cffi>=1.0.0 (from clipspy)
15.71 Using cached cffi-1.17.1-cp312-cp312-musllinux_1_1_x86_64.whl.metadata (1.5 kB)
15.79 Collecting pycparser (from cffi>=1.0.0->clipspy)
15.80 Using cached pycparser-2.22-py3-none-any.whl.metadata (943 bytes)
15.81 Using cached cffi-1.17.1-cp312-cp312-musllinux_1_1_x86_64.whl (488 kB)
15.81 Using cached pycparser-2.22-py3-none-any.whl (117 kB)
15.82 Building wheels for collected packages: clipspy
15.82 Building wheel for clipspy (pyproject.toml): started
16.61 Building wheel for clipspy (pyproject.toml): finished with status 'error'
16.62 error: subprocess-exited-with-error
16.62
16.62 × Building wheel for clipspy (pyproject.toml) did not run successfully.
16.62 │ exit code: 1
16.62 ╰─> [26 lines of output]
16.62 running bdist_wheel
16.62 running build
16.62 running build_py
16.62 creating build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/routers.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/modules.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/agenda.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/functions.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/values.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/clips_build.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/environment.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/facts.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/__init__.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/classes.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 copying clips/common.py -> build/lib.linux-x86_64-cpython-312/clips
16.62 running build_ext
16.62 generating cffi module 'build/temp.linux-x86_64-cpython-312/_clips.c'
16.62 creating build/temp.linux-x86_64-cpython-312
16.62 building '_clips' extension
16.62 creating build/temp.linux-x86_64-cpython-312/build/temp.linux-x86_64-cpython-312
16.62 gcc -fno-strict-overflow -Wsign-compare -DNDEBUG -g -O3 -Wall -fPIC -Iclips_source -I/usr/local/include/python3.12 -c build/temp.linux-x86_64-cpython-312/_clips.c -o build/temp.linux-x86_64-cpython-312/build/temp.linux-x86_64-cpython-312/_clips.o
16.62 build/temp.linux-x86_64-cpython-312/_clips.c:574:10: fatal error: clips.h: No such file or directory
16.62 574 | #include <clips.h>
16.62 | ^~~~~~~~~
16.62 compilation terminated.
16.62 error: command '/usr/bin/gcc' failed with exit code 1
16.62 [end of output]
16.62
16.62 note: This error originates from a subprocess, and is likely not a problem with pip.
16.62 ERROR: Failed building wheel for clipspy
16.62 Failed to build clipspy
17.37 ERROR: ERROR: Failed to build installable wheels for some pyproject.toml based projects (clipspy)
------
Dockerfile:4
--------------------
2 |
3 | RUN apk add build-base curl make
4 | >>> RUN pip install clipspy
5 |
6 | CMD ["python", "-c", "'from clips import __version__; print(__version__)'"]
--------------------
ERROR: failed to solve: process "/bin/sh -c pip install clipspy" did not complete successfully: exit code: 1
Dockerfile for installing CLIPS on an alpine docker image:
FROM python:3.12-alpine
RUN apk add build-base curl make
RUN curl --output clips.zip --location --url https://sourceforge.net/projects/clipsrules/files/CLIPS/6.4.1/clips_core_source_641.zip
RUN unzip -jo clips.zip -d clips_source
RUN (cd clips_source && make release)
ENTRYPOINT ["clips_source/clips"]
The text was updated successfully, but these errors were encountered:
Ok, I guess your issue depends on this. I remember Docker was introduced to simplify deployments across multiple environments and Linux distributions... 🤦
When trying to install clipspy on an alpine-based docker image (see Dockerfile below), I get an error (see below). I have been able to install clips on alpine without clipspy using
make release
and CLIPS'smakefile
(see last docker file below).I'd be happy to try and help making clipspy installable on alpine as well, as this is a popular docker image for running python. I'd just be happy to get some help understanding why clipspy is building CLIPS as it does.
Dockerfile for installing clipspy:
Error when running the above:
Dockerfile for installing CLIPS on an alpine docker image:
The text was updated successfully, but these errors were encountered: