On 06/01/14 00:26, Aymeric Augustin wrote:
> On 5 janv. 2014, at 22:54, Shai Berger wrote:
>
>> I'd go for __contains__:
>>
>> if "django.contrib.auth" in apps:
>
> I considered this one but I didn’t select it because it will restrict our
> freedom in the future.
>
> If I were to add mag
I am new to Django (converted from Drupal) and trying to learn Django
first before I dive into converting my site over from HTML,CSS and JS to
use Django and Python.
I have a question though. I am going through the Django Tutorial and
came across where it said this:
https://docs.djangoproject.c
Thanks for the feedback. I've added answers to all of your questions and a
few extra comments about why I did certain things. Feel free to ask more
questions on the pull request or ping me on IRC.
Regards,
Michael Manfre
On Sun, Jan 5, 2014 at 7:13 PM, Andrew Godwin wrote:
> I've left some com
On Mon, Jan 6, 2014 at 5:47 AM, Aymeric Augustin <
aymeric.augus...@polytechnique.org> wrote:
> On 5 janv. 2014, at 22:27, Josh Smeaton wrote:
>
> > The only thing I have against it is that it may sound like it can take
> an iterable of app names, where has_app() does not have that problem.
>
> W
I've left some comments on the PR - the overall approach is fine, and I'm
in favour of things like removing quote_parameter and adding params to the
deferred_sql entries - but there's a few stylistic questions and I'm
worried why you've removed the maximum index name length stuff.
As for not being
Hi.
First of all, a hug to Aymeric for this, very nice work!
My first thought was also on "is_installed", which seems natural.
But, on my second thought, the "has_app" is not that bad because it is a
method of the "app loading"; i.e. the apps "having" something makes sense
than "being" something
On 6 January 2014 10:11, Shai Berger wrote:
> On Sunday 05 January 2014 23:26:12 Aymeric Augustin wrote:
> > If I were to add magic methods on the app registry I’d probably make it a
> > dict of app_label => app_config. This is the most common use case.
> >
> > Then it would be inconsistent to su
On Sunday 05 January 2014 23:26:12 Aymeric Augustin wrote:
> On 5 janv. 2014, at 22:54, Shai Berger wrote:
> > I'd go for __contains__:
> > if "django.contrib.auth" in apps:
> I considered this one but I didn’t select it because it will restrict our
> freedom in the future.
>
> If I were to a
On 5 janv. 2014, at 22:54, Shai Berger wrote:
> I'd go for __contains__:
>
> if "django.contrib.auth" in apps:
I considered this one but I didn’t select it because it will restrict our
freedom in the future.
If I were to add magic methods on the app registry I’d probably make it a dict
+1 for "is_installed"
I don't find the grammar objectionable here, just think of it as "is_(each
one of these apps)_installed"
On Sunday, January 5, 2014 3:50:45 PM UTC-6, Aymeric Augustin wrote:
>
> On 5 janv. 2014, at 22:38, Raffaele Salmaso
> >
> wrote:
>
> > Should it takes a list of app
On Sunday 05 January 2014 22:47:22 Aymeric Augustin wrote:
> On 5 janv. 2014, at 22:27, Josh Smeaton wrote:
> > The only thing I have against it is that it may sound like it can take an
> > iterable of app names, where has_app() does not have that problem.
> What about is_installed?
I'd go for __
On 5 janv. 2014, at 22:38, Raffaele Salmaso wrote:
> Should it takes a list of apps, just to replace
> apps.is_installed('djagno.contrib.sites') and
> apps.is_installed('django.contrib.admin') and ...
> with
> apps.is_installed('django.contrib.sites', 'django.contrib.admin',...)
> ?
That’s an in
On Sun, Jan 5, 2014 at 10:11 PM, Aymeric Augustin
wrote:
> `apps.has_app(...)` is technically correct but I think we can find a better
> name. My current favorite is `apps.installed(…)`. It’s quite short and it’s
> reminiscent of INSTALLED_APPS. That makes (some) sense since the method tests
>
On 5 janv. 2014, at 22:27, Josh Smeaton wrote:
> The only thing I have against it is that it may sound like it can take an
> iterable of app names, where has_app() does not have that problem.
What about is_installed?
--
Aymeric.
--
You received this message because you are subscribed to
+1 on .installed() as it reads quite well. The only thing I have against it
is that it may sound like it can take an iterable of app names, where
has_app() does not have that problem. app_installed() is more accurate but
is longer and less nice to read. My 2 cents.
Cheers,
Josh
--
You receiv
On 05.01.2014, at 22:11, Aymeric Augustin
wrote:
> Hello,
>
> During the app_loading refactor, I introduced a method to test if a given
> application is enabled, and I named it `has_app`.
>
> Its main uses are detecting misconfigurations:
>
>if not apps.has_app('django.contrib.admin
Hello,
During the app_loading refactor, I introduced a method to test if a given
application is enabled, and I named it `has_app`.
Its main uses are detecting misconfigurations:
if not apps.has_app('django.contrib.admin'):
raise ImproperlyConfigured("Put 'django.contrib.admi
On Friday, December 27, 2013 8:23:06 AM UTC+8, Russell Keith-Magee wrote:
>
>
> Django itself is licensed under the BSD license. This license allows you
> to produce derivative works, provided you comply with the terms of the BSD
> license. That means you can apply whatever *additional* terms you
18 matches
Mail list logo