#7736: Differences in loading of applications between development server and
mod_python
------------------------------------------------------------+---------------
Reporter: Petr Marhoun <[EMAIL PROTECTED]> | Owner: nobody
Status: closed | Milestone:
Component: Core framework | Version:
SVN
Resolution: invalid | Keywords:
Stage: Unreviewed | Has_patch: 1
Needs_docs: 0 | Needs_tests: 0
Needs_better_patch: 0 |
------------------------------------------------------------+---------------
Changes (by mtredinnick):
* status: new => closed
* needs_better_patch: => 0
* resolution: => invalid
* needs_tests: => 0
* needs_docs: => 0
Comment:
I don't see this as a bug. Yes, there's a difference, but that's neither
here nor there. The assumption that all apps will be transparently loaded
immediately is the error here. It happens to do that with the dev server,
but it's not something that is indicated as "must happen". The
`get_apps()` function is called when required, but not earlier. Forcing it
to be called at arbitrary points in the pipeline is inconsistent and not
worth it.
If you want your code fragment to work, which depends upon the "server"
module being loaded, then make sure you explicitly import the "server"
module. It will make your code cleaner ("explicit is better than implicit"
and all that) and avoid dependencies on the timing of any particular piece
of lazy loading.
--
Ticket URL: <http://code.djangoproject.com/ticket/7736#comment:1>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---