| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
|
|
|
|
| |
Regression in ecf87ad513fd8af6e4a6093ed918723a7d88d5ca.
Thanks Collin Anderson for the report.
|
|
|
|
|
|
|
| |
This improves performance of import_string() by avoiding multiple
imports for the same path.
Thanks Andrew Godwin and Keryn Knight for the implementation idea.
|
|
|
|
| |
_NamespacePath supports indexing in Python 3.8+.
|
| |
|
| |
|
| |
|
|
|
|
| |
dotted path.
|
| |
|
|
|
|
| |
Thanks Tim Graham for the review.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There's no reason to assume that sys.path[0] is an appropriate location
for generating code. Specifically that doesn't work with extend_sys_path
which puts the additional directories at the end of sys.path.
In order to create a new migrations module, instead of using an
arbitrary entry from sys.path, import as much as possible from the path
to the module, then create missing submodules from there.
Without this change, the tests introduced in the following commit fail,
which seems sufficient to prevent regressions for such a refactoring.
|
| |
|
| |
|
|
|
|
| |
#21674.
|
|
|
|
| |
Thanks kostko for the report.
|
|
|
|
| |
Stopped using the imp module on Python >= 3.3. Refs #21628.
|
|
|
|
|
| |
Thanks Anssi Kääriäinen for the idea and Simon Charette for the
review.
|
|
|
|
|
|
| |
import_string().
Thanks Aymeric Augustin for the suggestion and review.
|
|
|
|
|
|
|
|
| |
Since the app registry is always populated before the first request is
processed, the situation described in #18251 for the old app cache
cannot happen any more.
Refs #18251, #21628.
|
|
|
|
| |
Eliminated the app_ prefix that was more confusing than useful.
|
|
|
|
|
|
| |
Also renamed app_cache to apps and "app cache" to "app registry".
Deprecated AppCache.app_cache_ready() in favor of Apps.ready().
|
|
|
|
| |
Reverted 4a56a93cc458e9ab4dcab95d9f5067d4975dd1a2.
|
|
|
|
| |
Used the app cache's get_app_configs() method instead.
|
| |
|
|
|
|
|
|
|
|
| |
We want to be able to use it for instance for discovering `tasks.py` modules
inside the INSTALLED_APPS.
This commit therefore moves the logic to `autodiscover_modules` method in
django.utils.module_loading.
|
| |
|
|
|
|
| |
This was a shim for pre-Python 2.7 support.
|
|
|
|
| |
Thanks @carljm for the review.
|
|
|
|
| |
Thanks Carl Meyer for the report.
|
|
|
|
|
|
| |
a python file
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16703 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
reasons this doesn't actually raise an error under CPython, but PyPy does, and the currently implementation is clearly in violation of the PEP, which states that finder.find_module's second argument is either None or package.__path__ and imp.find_module whose second argument should be either None or a list of paths.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16531 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
correct PEP 302, passing the package as the second argument to the find_module method of the importer. Thanks, Bradley Ayers.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16075 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
for an existent package. Thanks to Łukasz Rekucki for the report and patch, and to shields for the test case.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15362 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
loader and finder to be the same class. Thanks to Alex Gaynor for the report and patch, and Brett Cannon for suggesting the approach.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@13082 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
AppEngine. Thanks to Waldemar Kornewald for the report and testing help.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@13023 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
Ramiro and metzen for pointers on how to find out if a module loaded from an egg has a particular submodule.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12982 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|