After reading the docs, it turns out that `np.PyArray_FROM_OTF(a, np.NPY_LONG, np.NPY_ARRAY_FORCECAST) != np.PyArray_FROM_O(a)` prevents the error from occurring. -- Sent from: http://numpy-discussion.10968.n7.nabble.com/