Add default automatic imports to shell
It could be useful for the final shell's user to have some default imports to avoid extra work of customizing to the user. Following this discussion https://forum.djangoproject.com/t/default-automatic-imports-in-the-shell/33708 , it appears that the most used objects are:
- Utilities for date and timezone, namely
datetime and django.utils.timezone modules
- Utilites for making or debugging database queries, namely
django.db.models and django.db.models.functionsmodules
- Settings of your projects, namely
django.conf.settings
Change History
(18)
| Triage Stage: |
Unreviewed → Accepted
|
| Type: |
Cleanup/optimization → New feature
|
| Needs documentation: |
set
|
| Patch needs improvement: |
set
|
| Cc: |
Ülgen Sarıkavak added
|
| Needs documentation: |
unset
|
| Patch needs improvement: |
unset
|
| Needs documentation: |
unset
|
| Patch needs improvement: |
set
|
| Patch needs improvement: |
unset
|
| Patch needs improvement: |
set
|
| Patch needs improvement: |
unset
|
| Patch needs improvement: |
set
|
| Patch needs improvement: |
unset
|
| Patch needs improvement: |
set
|
| Patch needs improvement: |
unset
|
| Triage Stage: |
Accepted → Ready for checkin
|
| Resolution: |
→ fixed
|
| Status: |
assigned → closed
|
Accepting following positive forum discussion. Thank you Salvo for raising this ticket, and working on it!