- 23 Ara, 2013 1 kayıt (commit)
-
-
Claude Paroz yazdı
-
- 22 Ara, 2013 27 kayıt (commit)
-
-
Marc Tamlyn yazdı
It was not used inside Django, is not tested or documented. Consequently remove without deprecation path. Thanks to @vajrasky for bringing it to our attention.
-
Aymeric Augustin yazdı
-
Aymeric Augustin yazdı
-
Aymeric Augustin yazdı
-
Aymeric Augustin yazdı
-
Aymeric Augustin yazdı
That matches its return type better.
-
Aymeric Augustin yazdı
That matches its name ad its purpose better.
-
Aymeric Augustin yazdı
-
Aymeric Augustin yazdı
It is a public API.
-
Aymeric Augustin yazdı
Reverted 4a56a93c.
-
Aymeric Augustin yazdı
-
Aymeric Augustin yazdı
Currently such overrides aren't reflected in the app cache. It would be possible to handle them. But that doesn't look like a very good API. It makes it complicated to express "add this app" and "remove this app", which are the most common operations on INSTALLED_APPS.
-
Aymeric Augustin yazdı
- Tested consistency the current app_configs instead of INSTALLED_APPS. - Considered applications added with _with_app as available. - Added docstrings.
-
Aymeric Augustin yazdı
Except the app cache code and a few specific tests, of course.
-
Aymeric Augustin yazdı
Removed some exception masking in the comments app that was harmful and couldn't be preserved easily.
-
Aymeric Augustin yazdı
This avoids possible confusion with register_model. Thanks Marc Tamlyn for the suggestion.
-
Aymeric Augustin yazdı
Used the app cache's get_app_configs() method instead.
-
Aymeric Augustin yazdı
-
Aymeric Augustin yazdı
Took this opportunity to change get_app[s] to only consider applications containing a model module as that seems slightly more backwards compatible. Since callers that care about models pass only_with_models_module=True, this has very few consequences. Only AppCommand needed a change.
-
Aymeric Augustin yazdı
Adjusted several tests that used it to add apps to the app cache and then attempted to remove them by manipulating attributes directly. Also renamed invalid_models to invalid_models_tests to avoid clashing application labels between the outer and the inner invalid_models applications.
-
Aymeric Augustin yazdı
-
Aymeric Augustin yazdı
It was called _populate() before I renamed it to populate(). Since it has been superseded by populate_models() there's no reason to keep it. Removed the can_postpone argument of load_app() as it was only used by populate(). It's a private API and there's no replacement. Simplified load_app() accordingly. Then new version behaves exactly like the old one even though it's much shorter.
-
Aymeric Augustin yazdı
First stage imports app modules. It doesn't catch import errors. This matches the previous behavior and keeps the code simple. Second stage import models modules. It catches import errors and retries them after walking through the entire list once. This matches the previous behavior and seems useful. populate_models() is intended to be equivalent to populate(). It isn't wired yet. That is coming in the next commit.
-
Aymeric Augustin yazdı
Since applications that aren't installed no longer have an application configuration, it is now always True in practice. Provided an abstraction to temporarily add or remove applications as several tests messed with app_config.installed to achieve this effect. For now this API is _-prefixed because it looks dangerous.
-
Aymeric Augustin yazdı
It wasn't used anywhere and couldn't be implemented any more since non-installed apps no longer have a configuration.
-
Aymeric Augustin yazdı
Got rid of AppConfig._stub. As a side effect, app_cache.app_configs now only contains entries for applications that are in INSTALLED_APPS, which is a good thing and will allow dramatic simplifications (which I will perform in the next commit). That required adjusting all methods that iterate on app_configs without checking the "installed" flag, hence the large changes in get_model[s]. Introduced AppCache.all_models to store models: - while the app cache is being populated and a suitable app config object to register models isn't available yet; - for applications that aren't in INSTALLED_APPS since they don't have an app config any longer. Replaced get_model(seed_cache=False) by registered_model() which can be kept simple and safe to call at any time, and removed the seed_cache argument to get_model[s]. There's no replacement for that private API. Allowed non-master app caches to go through populate() as it is now safe to do so. They were introduced in 1.7 so backwards compatibility isn't a concern as long as the migrations framework keeps working.
-
Aymeric Augustin yazdı
-
- 21 Ara, 2013 1 kayıt (commit)
-
-
Alexey Voronov yazdı
Thanks Tim Graham for review.
-
- 20 Ara, 2013 4 kayıt (commit)
-
-
Aymeric Augustin yazdı
This reverts commit a25fe3b6. It didn't do anything. It merely added to every PO file: msgid "%(name)s" msgstr "%(name)s" Thanks Ramiro Morales for the report at: https://groups.google.com/d/msg/Django-I18N/vc2vQzv80UQ/EuaW38V7X7sJ Conflicts: django/contrib/admin/templates/admin/index.html
-
Aymeric Augustin yazdı
Refs #19031.
-
Alex Gaynor yazdı
-
Alex Hill yazdı
It's now consistent with RenderContext.get.
-
- 18 Ara, 2013 7 kayıt (commit)
-
-
Tim Graham yazdı
Thanks graeme.perrow at sap.com for the original report.
-
Tim Graham yazdı
Thanks Bruno Brouard for the report.
-
Ondrej Sika yazdı
-
Bouke Haarsma yazdı
* Removed ADMIN_FOR setting and warn warning * Group view functions by namespace instead of site * Added a test verifying namespaces are listed Thanks to Claude Paroz for reviewing and ideas for improvement.
-
Baptiste Mispelon yazdı
Callable arguments were an untested and undocumented feature.
-
Kevin Christopher Henry yazdı
Using callables as query parameters is undocumented and not working, so this changes an example from the ForeignKey.limit_choices_to documentation that uses it.
-
Denis Moskalets yazdı
Thanks Anubhav Joshi for the documentation.
-