[pypy-dev] AttributeError: 'built in-code' object has no attribute 'co_code'

Etienne Robillard tkadm30 at yandex.com
Fri Oct 13 07:22:40 EDT 2017


Hi Yury,

I upgraded pypy to 5.9.0 and cython to 0.27.1.

Compilation of libschevo fails under PyPy:

erob at marina:~/src/django-hotsauce-pypy/extras/libschevo$ sudo pypy 
setup.py develop --prefix=/usr/local/pypy
running develop
running egg_info
writing lib/libschevo.egg-info/PKG-INFO
writing dependency_links to lib/libschevo.egg-info/dependency_links.txt
writing entry points to lib/libschevo.egg-info/entry_points.txt
writing requirements to lib/libschevo.egg-info/requires.txt
writing top-level names to lib/libschevo.egg-info/top_level.txt
reading manifest file 'lib/libschevo.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching 'README' anywhere in distribution
warning: no files found matching '*' under directory 'schevo/templates'
writing manifest file 'lib/libschevo.egg-info/SOURCES.txt'
running build_ext
building 'schevo.store._s_persistent' extension
cc -pthread -DNDEBUG -O2 -fPIC 
-I/usr/local/pypy/pypy2-v5.9.0-linux32/include -c 
lib/schevo/store/_s_persistent.c -o 
build/temp.linux-i686-2.7/lib/schevo/store/_s_persistent.o
lib/schevo/store/_s_persistent.c:8:27: fatal error: weakrefobject.h: No 
such file or directory
  #include "weakrefobject.h"
                            ^
compilation terminated.
error: command 'cc' failed with exit status 1

Will need to investigate further why weakrefobject.h is missing from 
PyPy or find a workaround.

Best Regards,

Etienne



On 13/10/17 01:16 AM, Yury V. Zaytsev wrote:
>
> You are using very outdated versions of both PyPy (latest = 5.9.0) and 
> Cython (latest = 0.27.1), could you please try again with the latest 
> versions? There have been a lot of compatibility work going on both 
> sides, and it is not unlikely that the issue has been fixed in the 
> meantime.
>



More information about the pypy-dev mailing list