You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The reasons look good at the first glance. But sometimes people are already working with Record in dot notation. E.g. jinja or django templates allow to do this. And so people forced to use different syntax in their handlers and templates.
Yes, sure. In django views you should use record as a dict, but in templates you should use dot notation. I would prefer use dot notation in both cases.
That's understandable. One potential solution is to add the ability to specify a cursor factory, like psycopg does. I'll open a separate issue for this.
Activity
elprans commentedon Oct 31, 2016
See #13 for the rationale of why this is not a good idea.
imbolc commentedon Oct 31, 2016
The reasons look good at the first glance. But sometimes people are already working with
Recordin dot notation. E.g. jinja or django templates allow to do this. And so people forced to use different syntax in their handlers and templates.elprans commentedon Oct 31, 2016
Both Jinja and Django allow dot notation for getitem access, so this argument is invalid.
imbolc commentedon Oct 31, 2016
Yes, sure. In django views you should use record as a dict, but in templates you should use dot notation. I would prefer use dot notation in both cases.
elprans commentedon Oct 31, 2016
That's understandable. One potential solution is to add the ability to specify a cursor factory, like psycopg does. I'll open a separate issue for this.