Opened 13 years ago
Closed 13 years ago
#19556 closed Cleanup/optimization (needsinfo)
Extend url include to search all packages in a namespace path
| Reported by: | Owned by: | nobody | |
|---|---|---|---|
| Component: | Core (URLs) | Version: | 1.4 |
| Severity: | Normal | Keywords: | urls eggs |
| Cc: | hirokiky@… | Triage Stage: | Unreviewed |
| Has patch: | yes | Needs documentation: | yes |
| Needs tests: | yes | Patch needs improvement: | yes |
| Easy pickings: | yes | UI/UX: | no |
Description
When installing django eggs in the same namespace it is required to include each egg in the settings.py INSTALLED_APPS variable.
The following patch is intended to reduce the configuration when installing additional modules by only including the namespace and adding
urlpatterns += patterns('',
(r'', include('urls', 'namespace')),
)
The patch will search all package paths declared in the namespace and collect each urlpattern to create a consolidated urlpattern attribute which it appends to the last urlconf_module to return
Attachments (2)
Change History (5)
by , 13 years ago
| Attachment: | url_loader.diff added |
|---|
comment:1 by , 13 years ago
| Cc: | added |
|---|
comment:2 by , 13 years ago
| Needs documentation: | set |
|---|---|
| Needs tests: | set |
| Patch needs improvement: | set |
comment:3 by , 13 years ago
| Resolution: | → needsinfo |
|---|---|
| Status: | new → closed |
Again, we need a test case or small sample project showing us why we want this.
Patch to include all urls.py from a namespace package