Compilation of Cython files on master broken
See original GitHub issueIt appears that I am not able to pip install -v -e .
Ray from the master branch due to a compilation failure from the static_pointer_cast
symbol in memory.pxd
not being found. Compilation works on the 0.6.2 tag.
If you look at the log below, the exact error is:
/data/ray/python/ray/includes/task.pxi:2:0: 'libcpp/memory/static_pointer_cast.pxd' not found
Knowing nothing about Cython sources, this still strikes me as somewhat strange given that static_pointer_cast
is a symbol in memory.pxd
, not a file itself. Not sure why the Cython compiler would spit out the error as if that symbol was actually a header file.
Begin log:
[ 72%] Building CXX object src/ray/object_manager/CMakeFiles/object_manager_test.dir/test/object_manager_test.cc.o
Scanning dependencies of target rayletlib
[ 73%] Building CXX object src/ray/object_manager/CMakeFiles/object_manager_stress_test.dir/test/object_manager_stress_test.cc.o
[ 74%] Building CXX object src/ray/object_manager/CMakeFiles/object_manager.dir/object_manager.cc.o
[ 75%] Building CXX object src/ray/gcs/CMakeFiles/client_test.dir/client_test.cc.o
[ 76%] Building CXX object src/ray/raylet/CMakeFiles/task_dependency_manager_test.dir/task_dependency_manager_test.cc.o
[ 77%] Building CXX object src/ray/raylet/CMakeFiles/reconstruction_policy_test.dir/reconstruction_policy_test.cc.o
[ 78%] Building CXX object src/ray/raylet/CMakeFiles/worker_pool_test.dir/worker_pool_test.cc.o
[ 79%] Building CXX object src/ray/raylet/CMakeFiles/object_manager_integration_test.dir/object_manager_integration_test.cc.o
[ 79%] Building CXX object src/ray/raylet/CMakeFiles/rayletlib.dir/raylet.cc.o
[ 80%] Linking CXX executable logging_test
[ 81%] Linking CXX executable signal_test
Error compiling Cython file:
------------------------------------------------------------
...
from libc.stdint cimport uint8_t
from libcpp.memory cimport (
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:2:0: 'libcpp/memory/static_pointer_cast.pxd' not found
Error compiling Cython file:
------------------------------------------------------------
...
for arg in arguments:
if isinstance(arg, ObjectID):
references = c_vector[CObjectID]()
references.push_back((<ObjectID>arg).data)
task_args.push_back(
static_pointer_cast[CTaskArgument,
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:59:20: 'static_pointer_cast' is not a constant, variable or function identifier
Error compiling Cython file:
------------------------------------------------------------
...
for arg in arguments:
if isinstance(arg, ObjectID):
references = c_vector[CObjectID]()
references.push_back((<ObjectID>arg).data)
task_args.push_back(
static_pointer_cast[CTaskArgument,
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:59:40: Cannot convert 'CTaskArgument' to Python object
Error compiling Cython file:
------------------------------------------------------------
...
if isinstance(arg, ObjectID):
references = c_vector[CObjectID]()
references.push_back((<ObjectID>arg).data)
task_args.push_back(
static_pointer_cast[CTaskArgument,
CTaskArgumentByReference](
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:60:40: Cannot convert 'CTaskArgumentByReference' to Python object
Error compiling Cython file:
------------------------------------------------------------
...
references = c_vector[CObjectID]()
references.push_back((<ObjectID>arg).data)
task_args.push_back(
static_pointer_cast[CTaskArgument,
CTaskArgumentByReference](
make_shared[CTaskArgumentByReference](references)))
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:61:61: Cannot convert 'shared_ptr[CTaskArgumentByReference]' to Python object
Error compiling Cython file:
------------------------------------------------------------
...
if isinstance(arg, ObjectID):
references = c_vector[CObjectID]()
references.push_back((<ObjectID>arg).data)
task_args.push_back(
static_pointer_cast[CTaskArgument,
CTaskArgumentByReference](
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:60:65: Cannot convert Python object to 'shared_ptr[CTaskArgument]'
Error compiling Cython file:
------------------------------------------------------------
...
make_shared[CTaskArgumentByReference](references)))
else:
pickled_str = pickle.dumps(
arg, protocol=pickle.HIGHEST_PROTOCOL)
task_args.push_back(
static_pointer_cast[CTaskArgument,
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:66:20: 'static_pointer_cast' is not a constant, variable or function identifier
Error compiling Cython file:
------------------------------------------------------------
...
make_shared[CTaskArgumentByReference](references)))
else:
pickled_str = pickle.dumps(
arg, protocol=pickle.HIGHEST_PROTOCOL)
task_args.push_back(
static_pointer_cast[CTaskArgument,
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:66:40: Cannot convert 'CTaskArgument' to Python object
Error compiling Cython file:
------------------------------------------------------------
...
else:
pickled_str = pickle.dumps(
arg, protocol=pickle.HIGHEST_PROTOCOL)
task_args.push_back(
static_pointer_cast[CTaskArgument,
CTaskArgumentByValue](
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:67:40: Cannot convert 'CTaskArgumentByValue' to Python object
Error compiling Cython file:
------------------------------------------------------------
...
pickled_str = pickle.dumps(
arg, protocol=pickle.HIGHEST_PROTOCOL)
task_args.push_back(
static_pointer_cast[CTaskArgument,
CTaskArgumentByValue](
make_shared[CTaskArgumentByValue](
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:68:57: Cannot convert 'shared_ptr[CTaskArgumentByValue]' to Python object
Error compiling Cython file:
------------------------------------------------------------
...
else:
pickled_str = pickle.dumps(
arg, protocol=pickle.HIGHEST_PROTOCOL)
task_args.push_back(
static_pointer_cast[CTaskArgument,
CTaskArgumentByValue](
^
------------------------------------------------------------
/data/ray/python/ray/includes/task.pxi:67:61: Cannot convert Python object to 'shared_ptr[CTaskArgument]'
[ 81%] Built target logging_test
[ 81%] Built target signal_test
make[2]: *** [python/_raylet.cxx] Error 1
make[2]: *** Deleting file `python/_raylet.cxx'
make[1]: *** [python/CMakeFiles/_raylet.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 82%] Linking CXX executable task_test
Conda env:
# packages in environment at /scratch/anaconda3/envs/raydev:
#
# Name Version Build Channel
asn1crypto 0.24.0 pypi_0 pypi
astroid 2.1.0 py37_0
atomicwrites 1.3.0 py_0
attrs 18.2.0 py37h28b3542_0
bcrypt 3.1.6 pypi_0 pypi
blas 1.0 mkl
bzip2 1.0.6 h14c3975_5
ca-certificates 2019.1.23 0
cairo 1.14.12 h8948797_3
certifi 2018.11.29 py37_0
cffi 1.12.1 pypi_0 pypi
click 7.0 pypi_0 pypi
colorama 0.4.1 pypi_0 pypi
cryptography 2.5 pypi_0 pypi
cycler 0.10.0 py37_0
cython 0.29 py37he6710b0_0
dbus 1.13.6 h746ee38_0
docopt 0.6.2 pypi_0 pypi
expat 2.2.6 he6710b0_0
ffmpeg 4.0 hcdf2ecd_0
filelock 3.0.10 pypi_0 pypi
flatbuffers 1.10 pypi_0 pypi
fontconfig 2.13.0 h9420a91_0
freeglut 3.0.0 hf484d3e_5
freetype 2.9.1 h8a8886c_1
funcsigs 1.0.2 pypi_0 pypi
gitdb2 2.0.5 py37_0
gitpython 2.1.11 py37_0
glib 2.56.2 hd408876_0
graphite2 1.3.13 h23475e2_0
gst-plugins-base 1.14.0 hbbd80ab_1
gstreamer 1.14.0 hb453b48_1
harfbuzz 1.8.8 hffaf4a1_0
hdf5 1.10.2 hba1933b_1
icu 58.2 h9c2bf20_1
intel-openmp 2019.1 144
isort 4.3.4 py37_0
jasper 2.0.14 h07fcdf6_1
jpeg 9b h024ee3a_2
jsonpickle 0.9.6 pypi_0 pypi
kiwisolver 1.0.1 py37hf484d3e_0
lazy-object-proxy 1.3.1 py37h14c3975_2
libedit 3.1.20181209 hc058e9b_0
libffi 3.2.1 hd88cf55_4
libgcc 7.2.0 h69d50b8_2
libgcc-ng 8.2.0 hdf63c60_1
libgfortran-ng 7.3.0 hdf63c60_0
libglu 9.0.0 hf484d3e_1
libopencv 3.4.2 hb342d67_1
libopus 1.3 h7b6447c_0
libpng 1.6.36 hbc83047_0
libstdcxx-ng 8.2.0 hdf63c60_1
libtiff 4.0.10 h2733197_2
libuuid 1.0.3 h1bed415_2
libvpx 1.7.0 h439df22_0
libxcb 1.13 h1bed415_1
libxml2 2.9.9 he19cac6_0
matplotlib 3.0.2 py37h5429711_0
mccabe 0.6.1 py37_1
mkl 2019.1 144
mkl_fft 1.0.10 py37ha843d7b_0
mkl_random 1.0.2 py37hd81dba3_0
more-itertools 5.0.0 py37_0
munch 2.3.2 pypi_0 pypi
ncurses 6.1 he6710b0_1
nodejs 10.13.0 he6710b0_0
numpy 1.15.4 py37h7e9f1db_0
numpy-base 1.15.4 py37hde5b4d6_0
olefile 0.46 py37_0
opencv 3.4.2 py37h6fd60c2_1
openssl 1.1.1a h7b6447c_0
pandas 0.24.1 py37he6710b0_0
paramiko 2.4.2 pypi_0 pypi
pcre 8.42 h439df22_0
pillow 5.4.1 py37h34e0f95_0
pip 19.0.1 py37_0
pixman 0.36.0 h7b6447c_0
pluggy 0.8.1 py37_0
py 1.7.0 py37_0
py-cpuinfo 4.0.0 pypi_0 pypi
py-opencv 3.4.2 py37hb342d67_1
pyasn1 0.4.5 pypi_0 pypi
pycparser 2.19 pypi_0 pypi
pylint 2.2.2 py37_0
pymongo 3.7.2 py37he6710b0_0
pynacl 1.3.0 pypi_0 pypi
pyparsing 2.3.1 py37_0
pyqt 5.9.2 py37h05f1152_2
pytest 4.2.1 py37_0
python 3.7.2 h0371630_0
python-dateutil 2.7.5 py37_0
pytz 2018.9 py37_0
pyyaml 3.13 py37h14c3975_0
qt 5.9.7 h5867ecd_1
readline 7.0 h7b6447c_5
redis 3.2.0 pypi_0 pypi
sacred 0.7.4 pypi_0 pypi
setuptools 40.8.0 py37_0
sip 4.19.8 py37hf484d3e_0
six 1.12.0 py37_0
smmap2 2.0.5 py37_0
spur 0.3.20 pypi_0 pypi
sqlite 3.26.0 h7b6447c_0
tk 8.6.8 hbc83047_0
tornado 5.1.1 py37h7b6447c_0
typing 3.6.6 pypi_0 pypi
wheel 0.32.3 py37_0
wrapt 1.11.1 py37h7b6447c_0
xxhash 1.3.0 pypi_0 pypi
xz 5.2.4 h14c3975_4
yaml 0.1.7 had09818_2
zlib 1.2.11 h7b6447c_3
zstd 1.3.7 h0b5b093_0
Issue Analytics
- State:
- Created 5 years ago
- Comments:9 (9 by maintainers)
Top Results From Across the Web
Something wrong when I compile cython with C++
I try to compile the OpenSource Cython Project(https://github.com/seanbell/intrinsic) with gcc. But something is wrong when I use the orde " ...
Read more >Source Files and Compilation - Cython's Documentation
Compiling with the cython command¶. One way is to compile it manually with the Cython compiler, e.g.: $ cython primes.pyx.
Read more >Re: [cython-users] Compile multiple Cython objects into single ...
Is it possible to compile multiple Cython objects into one shared library without including them into one master C file?
Read more >NetworKit Development Guide
NetworKit Development Guide. This guide is designed to give potential contributors a quick understanding of the structure of NetworKit as well as what...
Read more >Python Bindings: Calling C or C++ From Python
The approach Cython takes to creating Python bindings uses a Python-like language to define the bindings and then generates C or C++ code...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ok cool, let me know if it helps. Two people from our side had the same problem and doing a fresh recompile fixed it for them (something old must be cached somewhere).
Have to head out for the day, but will try when I get back in. Thanks!