Opened 12 years ago
Closed 11 years ago
#21255 closed Bug (fixed)
Django doesn't closes connection when running from management command
| Reported by: | Owned by: | ||
|---|---|---|---|
| Component: | Database layer (models, ORM) | Version: | 1.5 |
| Severity: | Normal | Keywords: | connection postgres management |
| Cc: | tuxcanfly | 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
When runing django from mangemnt command
Django doesn't closes database connection
Walkaround to problem may be found here: http://stackoverflow.com/questions/16841505/django-resetting-postgres-connection
I think this is a django bug, and django should close connection by it self
When runned as ./manage.py shell
Connection should be automatically closed as well
Change History (7)
comment:1 by , 12 years ago
| Type: | Uncategorized → Bug |
|---|
comment:2 by , 12 years ago
| Triage Stage: | Unreviewed → Accepted |
|---|
comment:3 by , 12 years ago
| Cc: | added |
|---|---|
| Has patch: | set |
| Owner: | changed from to |
| Status: | new → assigned |
Submitted a pull request: https://github.com/django/django/pull/1748
comment:4 by , 11 years ago
| Patch needs improvement: | set |
|---|
Current PR has comments for improvement. Please uncheck "Patch needs improvement" when you update it, thanks.
comment:5 by , 11 years ago
| Owner: | removed |
|---|---|
| Patch needs improvement: | unset |
| Status: | assigned → new |
comment:6 by , 11 years ago
| Triage Stage: | Accepted → Ready for checkin |
|---|
comment:7 by , 11 years ago
| Owner: | set to |
|---|---|
| Resolution: | → fixed |
| Status: | new → closed |
Yes, the base class for management commands should call
django.db.close_connectionbefore exiting.