Changes between Version 50 and Version 51 of DjangoSpecifications/Core/Threading
- Timestamp:
- Apr 28, 2008, 4:06:49 AM (17 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
DjangoSpecifications/Core/Threading
v50 v51 37 37 }}} 38 38 is not that common. No code where duplicated call would cause a considerable overhead or harmful side-effects was found during the review, so '''the "inefficiency issues" are really non-issues''' and listed below only for reference. In the multi-process case each process does initialize `foo` individually anyway. 39 40 Note that as modules are cached, duplicate `__import__` calls don't re-import modules. 39 41 40 42 === Errors due to incomplete initialization === … … 97 99 ||utils/_decimal.py||lots, including code||MODULE LEVEL INIT, not reviewed|||| 98 100 ||django/contrib/sites/models.py||`SITE_CACHE`||OK||one db hit intended, more than one possible|| 99 ||django/template/context.py||`_standard_context_processors`||OK||d uplicated module loading with `__import__` possible||100 ||`django/template/__init__.py`||`invalid_var_format_string, libraries, builtins`||OK||d uplicated module loading with `__import__` possible||101 ||django/template/loader.py||`template_source_loaders`||PROBLEM, see #6950, patch attached||d uplicated module loading with `__import__` possible||101 ||django/template/context.py||`_standard_context_processors`||OK||double `__import__`|| 102 ||`django/template/__init__.py`||`invalid_var_format_string, libraries, builtins`||OK||double `__import__`|| 103 ||django/template/loader.py||`template_source_loaders`||PROBLEM, see #6950, patch attached||double `__import__`|| 102 104 ||django/template/loaders/app_directories.py||`app_template_dirs`||MODULE LEVEL INIT|||| 103 105 ||django/utils/translation/trans_real.py||`_accepted, _active, _default, _translations`||OK||explicit threading support, no inefficiencies|| 104 ||django/core/urlresolvers.py||`_callable_cache, _resolver_cache`||OK, `memoize` decorator||d uplicated module loading with `__import__` possible||106 ||django/core/urlresolvers.py||`_callable_cache, _resolver_cache`||OK, `memoize` decorator||double `__import__`|| 105 107 ||`django/core/serializers/__init__.py`||`_serializers`||PROBLEM, incomplete init in `_load_serializers`|||| 106 108 ||django/db/models/fields/related.py||`pending_lookups`||OK?, needs further review||`append()` in `add_lazy_relation()` can add duplicated values, which may or may not confuse `pop()` in `do_pending_lookups()`||