#25226 closed Bug (fixed)
ArrayField doesn't set the model attribute on the base_field instance
| Reported by: | Ion Scerbatiuc | Owned by: | |
|---|---|---|---|
| Component: | contrib.postgres | Version: | dev |
| Severity: | Normal | Keywords: | arrayfield check-framework |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | yes | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
I found this issue while working on #25172. The ArrayField uses the check framework to perform backend specific checks on the base_field instance, but doesn't set the model attribute on it.
Since the backend specific field tests will use the model to route to the appropriate db connection, we need to have the model set on the base_field instance too.
Here's the PR in github with the proposed fix: https://github.com/django/django/pull/5104
Attachments (1)
Change History (3)
by , 10 years ago
| Attachment: | arrayfield-set-model-on-base-field.diff added |
|---|
comment:2 by , 9 years ago
| Needs documentation: | unset |
|---|---|
| Needs tests: | unset |
| Patch needs improvement: | unset |
In 2e557908:
Note:
See TracTickets
for help on using tickets.
The proposed fix