wesm/pandas — Issue #485: Cython required on install
Author: mattharrison
Created: 2011-12-13 18:48:39+00:00
State: open

I had a few issues during install. I first created a virtual env, then pip installed pandas. It appeared to work but I got the following error when trying to import pandas:

```
Traceback (most recent call last):
File "test.py", line 2, in
from pandas import DataFrame, Series, read_csv
File "/home/mharrison/work/pandas/env/lib/python2.6/site-packages/pandas/__init__.py", line 10, in
import pandas._tseries as lib
ImportError: /home/mharrison/work/pandas/env/lib/python2.6/site-packages/pandas/_tseries.so: undefined symbol: PyArray_IsIntegerScalar
```

I then went back and read the install docs (yeah, did that backwards) and noticed that my numpy on Ubuntu 10.10 was not at 1.6.1. So I upgraded that and then tried to install pandas from git.

Got the following error:

```
$ python setup.py install
Traceback (most recent call last):
File "setup.py", line 292, in
depends=tseries_depends + ['pandas/src/numpy_helper.h'],
TypeError: unsupported operand type(s) for +: 'NoneType' and 'list'
```

I changed tseries_depends to a `[]` instead of `None` and it progressed furhter but still bailed out:

```
opying pandas/io/tests/test.xls -> build/lib.linux-i686-2.6/pandas/io/tests
running build_ext
Traceback (most recent call last):
File "setup.py", line 355, in
**setuptools_args)
File "/usr/lib/python2.6/distutils/core.py", line 152, in setup
dist.run_commands()
File "/usr/lib/python2.6/distutils/dist.py", line 975, in run_commands
self.run_command(cmd)
File "/usr/lib/python2.6/distutils/dist.py", line 995, in run_command
cmd_obj.run()
File "/usr/lib/python2.6/distutils/command/install.py", line 615, in run
self.run_command('build')
File "/usr/lib/python2.6/distutils/cmd.py", line 333, in run_command
self.distribution.run_command(command)
File "/usr/lib/python2.6/distutils/dist.py", line 995, in run_command
cmd_obj.run()
File "/usr/lib/python2.6/distutils/command/build.py", line 135, in run
self.run_command(cmd_name)
File "/usr/lib/python2.6/distutils/cmd.py", line 333, in run_command
self.distribution.run_command(command)
File "/usr/lib/python2.6/distutils/dist.py", line 995, in run_command
cmd_obj.run()
File "/usr/lib/python2.6/distutils/command/build_ext.py", line 340, in run
self.build_extensions()
File "setup.py", line 239, in build_extensions
self.check_cython_extensions(self.extensions)
File "setup.py", line 236, in check_cython_extensions
""" % src)
Exception: Cython-generated file 'pandas/src/tseries.c' not found.
Cython is required to compile pandas from a development branch.
Please install Cython or download a release package of pandas.

```

So I pip installed cython and I think I'm good now.