|Subject:||Add quotes in error messages where a named thing wasn't found|
|Date:||Wed, 11 Jan 2017 14:14:51 +0000|
|From:||Ben Hutton <firstname.lastname@example.org>|
I just spent half an hour trying to understand my error message. Turns out I was trying to get column “patient_id,”, but I didn’t see the additional comma. Granted it was totally my mistake.
On sharing with my colleagues, one mentioned that he had the same issue but with a space, and with relationship names also.
It seems reasonable and helpful to encapsulate the name of things in errors, in quotes, making it much easier to see you’ve made a mistake, and DBIx Class hasn’t suddenly decided a column you know is there, to not be found.