Opened 2 years ago
Closed 2 years ago
#33964 closed Bug (worksforme)
get_FOO_display() doesn't work with field named that include underscore
Reported by: | Viktor Ovsiannikov | Owned by: | nobody |
---|---|---|---|
Component: | Database layer (models, ORM) | Version: | 4.1 |
Severity: | Normal | Keywords: | get_FOO_display() model |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
If you try to use a get_FOO_display method on a field that contains underscore, it apparently breaks the syntax and the method doesn't work
Note:
See TracTickets
for help on using tickets.
The following test passes for me. Please provide details to reproduce.
tests/model_regress/models.py
tests/model_regress/tests.py