On 02/26/2015 12:30 AM, Augustus Saunders wrote:
Seems a little backwards to create a helper to work around a core defect. This is something that should work transparently, and is very simple to do so.
You are correct in your overall diagnosis, you are incorrect wrt the detail and the solution.
The problem is that DBIC "touches" some of the values returned from the DBD (even something as innocuous as $something->{$column_value} is enough to break the assumptions of a naive serializer).
The solution is to eliminate all these instances, and definitively not introducing expensive operations on every single value retrieval. Some work has been planned for this, but an audit of all code paths is decidedly not an easy task (and having an incomplete fix in this case is worse than not having any at all).
For the time being if you need proper *dependable* numeric semantics you should use the ::Row::NumifyGet helper as suggested, until its documentation is updated with 'DBIC now does this automatically'.
Cheers _______________________________________________ List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class IRC: irc.perl.org#dbix-class SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/ Searchable Archive: http://www.grokbase.com/group/dbix-class@lists.scsys.co.uk