weird, maybe a little OT, but two weeks ago (when ...
# general
a
weird, maybe a little OT, but two weeks ago (when I last worked on migrating to pants) my builds worked fine. Now, pip fails trying to build
pyzmq
(presumably before, it was using binaries) Have a constraints file, no other changes. kinda baffled
h
What's the failure?
a
Copy code
/tmp/process-executionFQMN5g/.tmp/timer_createhi0gwvus.c:2: undefined reference to `timer_create'
  collect2: error: ld returned 1 exit status
  no timer_create, linking librt
  ************************************************
  building 'zmq.libzmq' extension
  creating build/temp.linux-x86_64-3.9/buildutils
  creating build/temp.linux-x86_64-3.9/bundled
  creating build/temp.linux-x86_64-3.9/bundled/zeromq
  creating build/temp.linux-x86_64-3.9/bundled/zeromq/src
  x86_64-linux-gnu-g++ -pthread -std=c++11 -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -ffile-prefix-map=/build/python3.9-RNBry6/python3.9-3.9.2=. -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -ffile-prefix-map=/build/python3.9-RNBry6/python3.9-3.9.2=. -fstack-protector-strong -Wformat -Werror=format-security -fPIC -DZMQ_HAVE_CURVE=1 -DZMQ_USE_TWEETNACL=1 -DZMQ_USE_EPOLL=1 -DZMQ_IOTHREADS_USE_EPOLL=1 -DZMQ_POLL_BASED_ON_POLL=1 -Ibundled/zeromq/include -Ibundled -I/root/.cache/pants/named_caches/pex_root/venvs/short/afc7a36e/include -I/usr/include/python3.9 -c buildutils/initlibzmq.cpp -o build/temp.linux-x86_64-3.9/buildutils/initlibzmq.o
  buildutils/initlibzmq.cpp:10:10: fatal error: Python.h: No such file or directory
     10 | #include "Python.h"
        |          ^~~~~~~~~~
  compilation terminated.
  error: command '/usr/bin/x86_64-linux-gnu-g++' failed with exit code 1
  ----------------------------------------
  ERROR: Failed building wheel for pyzmq
ERROR: Failed to build one or more wheels
so it's failing to build the pyzmq package
(which is understandable, I haven't installed any build stuff on the CI runner)
but two weeks ago, it was using the binary packages
h
That is weird. Has your environment changed at all, like new machine or OS upgrade? Pants version change?
a
I think I found it.
👀 1
my CI was running in the image
python:3.8
if I change it to
python:3.8.10
then it works
(i think)
yes!
1
h
huh! btw I don't think that's a Pants thing, but rather Pex which itself is using pip. I wonder if you were to
pip install
if you'd get similar behavior of using prebuilt wheel vs compiling sdist
a
yeah, this is what was making it baffling
as locally, pyenv (while it was working), was set to use 3.8.10
👍 1
which is now another thing that's not workingrage4