#23451 closed Bug (fixed)
inlineformset_factory with wrong fk_name throws ValueError with wrong message
| Reported by: | petraszd | Owned by: | petraszd | 
|---|---|---|---|
| Component: | Forms | Version: | 1.7 | 
| Severity: | Normal | Keywords: | |
| Cc: | Triage Stage: | Ready for checkin | |
| Has patch: | yes | Needs documentation: | no | 
| Needs tests: | no | Patch needs improvement: | no | 
| Easy pickings: | no | UI/UX: | no | 
Description
Because of typo, passing wrong fk_name kwarg causes inlineformset_factory to throw ValueError with cryptic message:
"unsupported format character  (0x27) at index 41"
Instead of nice formatted one: "fk_name 'foo' is not a ForeignKey to 'foo.Foo'."
Change History (4)
comment:1 by , 11 years ago
| Has patch: | set | 
|---|---|
| Status: | new → assigned | 
comment:2 by , 11 years ago
| Triage Stage: | Unreviewed → Ready for checkin | 
|---|---|
| Version: | master → 1.7 | 
Will add release notes and commit this.
comment:3 by , 11 years ago
| Resolution: | → fixed | 
|---|---|
| Status: | assigned → closed | 
  Note:
 See   TracTickets
 for help on using tickets.
    
Fixed in: https://github.com/django/django/pull/3198