
On Fri, Jun 21, 2013 at 7:09 AM, Richard Hattersley <rhattersley@gmail.com>wrote:
Hi all,
In my continuing adventures in the Land of Custom Dtypes I've come across some rather disappointing behaviour in 1.7 & 1.8.
I've defined my own class `Time360`, and a corresponding dtype `time360` which references Time360 as its scalar type.
t = Time360(2013, 6, 29) np.array([t]).dtype
Now with 1.6.2 I can do: dtype('Time360')
And since all the instances supplied to the function were instances of the scalar type for my dtype, numpy automatically created an array using my dtype. Happy days!
np.array([t]).dtype
But in 1.7 and 1.8 I get: dtype('O')
So now I just get a plain old object array. Boo! Hiss!
Is this expected? Desirable? An unwanted regression?
Bit short on detail here ;) How did you create/register the dtype? Chuck