`PyObject_Unicode` doesn't exist in python 3 as `str` is unicode. I think you need some `#if defined(NPY_PY3K)` in appropriate places.
`