Re: Proposal: deprecate and remove egg template loader

2015-07-14 Thread Federico Capoano
+1 
I am assuming the deprecation is done according to the process that was 
discussed in the thread "An easier path to upgrade from one LTS release to 
another".


On Sunday, July 12, 2015 at 4:53:23 PM UTC+2, James Bennett wrote:
>
> There's not much to this, really, except what's in the subject line of 
> this message.
>
> The problem of providing a single-file, no-build-step format for 
> distributing and installing Python packages has been solved by wheels, and 
> wheels also don't cause the pile of weirdness that comes with using eggs.
>
> So Django should really stop encouraging/supporting the use of eggs. At a 
> minimum, this should involve Django 1.9 starting the deprecation process 
> for the egg template loader, and any other parts of Django which contain 
> special-case workarounds to deal with eggs.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/691ba2b2-9a45-470a-afe8-3a7bd0508a97%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Support for UNLOGGED tables in PostgreSQL

2015-07-14 Thread Federico Capoano
That's also a viable alternative, although it also mention unlogged tables,
which are not supported by django.

We could list the quick hint with config sample, a link to pg non durable
options page and a warning that UNLOGGED tables are not supported yet. What
do you think about this?

BTW has anyone had the time to try unlogged tables with their test suite to
see if it gave them any improvements? I am quite surprised i didn't even
get a 5-10% improvement out of the promised 10-17%.

Federico
Wouldn't it be enough to just have link to the correct PostgreSQL site:
http://www.postgresql.org/docs/current/static/non-durability.html
And then some text with "if you want to run your tests on postgresql please
see the docs around non durable postgres"

2015-07-13 18:46 GMT+02:00 Federico Capoano :

> Sure, i've just done something similar for this project:
>
> http://nodeshot.readthedocs.org/en/latest/topics/install_development.html#how-to-setup-the-test-environment
>
> The *keepdb* option allows to avoid recreating the test database at each
> run, hence saving precious time.
>
> If you want to speed up tests even more, tweak your local postgresql
> configuration by setting these values:
>
> # /etc/postgresql/9.1/main/postgresql.conf
> # only for development!
> fsync = off
> synchronous_commit = off
> full_page_writes = off
>
>
> We just have to make sure people actually find this information via search
> engines.
>
> The best thing would be to have a subsection called "How to speed up tests
> with Postgres" or something similar.
>
> What do you think?
>
> Federico
>
>
>
> On Monday, July 13, 2015 at 5:54:08 PM UTC+2, Aymeric Augustin wrote:
>>
>> Hello Federico,
>>
>> 2015-07-13 16:26 GMT+02:00 Federico Capoano :
>>
>>> While these are the winners:
>>>
>>>- fsync = off
>>>- synchronous_commit = off
>>>- full_page_writes = off
>>>
>>> Would you like to submit a patch to docs/ref/databases.txt, in the
>> "PostgreSQL
>> notes" section, explaining this configuration?
>>
>> I'm sure it would help many people run their tests faster on PostgreSQL.
>> It would
>> also counter the trend to run tests on SQLite "because it's faster" — it
>> isn't.
>>
>> --
>> Aymeric.
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To post to this group, send email to django-developers@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-developers.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/7c3c1b6c-68f5-4cf0-b2db-d5fa58a6930d%40googlegroups.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

 --
You received this message because you are subscribed to a topic in the
Google Groups "Django developers (Contributions to Django itself)" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/django-developers/IkRgMxTTzPQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-developers/CAPDLAU7bYbeYb7pRgmqTR--zUrdU0fJyB5mHPWHoGEgawbB-MA%40mail.gmail.com

.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAERYH6XLR6idaHzYOuuJ65iR%3DqXw8FsTvCyj-8OfjSeMAmS5qA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: metaclass expertise needed on migrations bug

2015-07-14 Thread Markus Holtermann

Thanks for brining this to my attention, Tim! I just commented on the
issue: https://code.djangoproject.com/ticket/25068#comment:12

/Markus

On Thu, Jul 09, 2015 at 01:13:11PM -0700, Tim Graham wrote:

To someone with experience with metaclasses,

A high-level overview of this ticket/pull request would be appreciated:

https://code.djangoproject.com/ticket/25068
https://github.com/django/django/pull/4968

--
You received this message because you are subscribed to the Google Groups "Django 
developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/e59496cd-f666-44c7-b583-a8f147d95e9c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--

--
You received this message because you are subscribed to the Google Groups "Django 
developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/20150714124947.GA7894%40pyler.local.
For more options, visit https://groups.google.com/d/optout.


pgpRDQBSNE6Oh.pgp
Description: PGP signature


Re: Fellow Report - July 11, 2015

2015-07-14 Thread Tom Christie
Consistently bloody amazing.
Thanks for doing such a great job.

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/1f9ff3f3-32cf-4adb-9c9d-9d9f51b295d0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Support for UNLOGGED tables in PostgreSQL

2015-07-14 Thread Tim Graham
I see a thirty second increase in the test suite (from 7.5 minutes to 8 
minutes) on my local machine with:

sql_create_table = "CREATE UNLOGGED TABLE %(table)s (%(definition)s)"

On Tuesday, July 14, 2015 at 4:20:45 AM UTC-4, Federico Capoano wrote:
>
> That's also a viable alternative, although it also mention unlogged 
> tables, which are not supported by django.
>
> We could list the quick hint with config sample, a link to pg non durable 
> options page and a warning that UNLOGGED tables are not supported yet. What 
> do you think about this?
>
> BTW has anyone had the time to try unlogged tables with their test suite 
> to see if it gave them any improvements? I am quite surprised i didn't even 
> get a 5-10% improvement out of the promised 10-17%.
>
> Federico
> Wouldn't it be enough to just have link to the correct PostgreSQL site: 
> http://www.postgresql.org/docs/current/static/non-durability.html
> And then some text with "if you want to run your tests on postgresql 
> please see the docs around non durable postgres"
>
> 2015-07-13 18:46 GMT+02:00 Federico Capoano  >:
>
>> Sure, i've just done something similar for this project:
>>
>> http://nodeshot.readthedocs.org/en/latest/topics/install_development.html#how-to-setup-the-test-environment
>>
>> The *keepdb* option allows to avoid recreating the test database at each 
>> run, hence saving precious time.
>>
>> If you want to speed up tests even more, tweak your local postgresql 
>> configuration by setting these values:
>>
>> # /etc/postgresql/9.1/main/postgresql.conf
>> # only for development!
>> fsync = off
>> synchronous_commit = off
>> full_page_writes = off
>>
>>
>> We just have to make sure people actually find this information via 
>> search engines.
>>
>> The best thing would be to have a subsection called "How to speed up 
>> tests with Postgres" or something similar.
>>
>> What do you think?
>>
>> Federico
>>
>>
>>
>> On Monday, July 13, 2015 at 5:54:08 PM UTC+2, Aymeric Augustin wrote:
>>>
>>> Hello Federico,
>>>
>>> 2015-07-13 16:26 GMT+02:00 Federico Capoano :
>>>
 While these are the winners:

- fsync = off
- synchronous_commit = off
- full_page_writes = off

 Would you like to submit a patch to docs/ref/databases.txt, in the 
>>> "PostgreSQL
>>> notes" section, explaining this configuration?
>>>
>>> I'm sure it would help many people run their tests faster on PostgreSQL. 
>>> It would
>>> also counter the trend to run tests on SQLite "because it's faster" — it 
>>> isn't.
>>>
>>> -- 
>>> Aymeric.
>>>  
>>  -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Django developers (Contributions to Django itself)" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to django-develop...@googlegroups.com .
>> To post to this group, send email to django-d...@googlegroups.com 
>> .
>> Visit this group at http://groups.google.com/group/django-developers.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/django-developers/7c3c1b6c-68f5-4cf0-b2db-d5fa58a6930d%40googlegroups.com
>>  
>> 
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>  -- 
> You received this message because you are subscribed to a topic in the 
> Google Groups "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this topic, visit 
> https://groups.google.com/d/topic/django-developers/IkRgMxTTzPQ/unsubscribe
> .
> To unsubscribe from this group and all its topics, send an email to 
> django-develop...@googlegroups.com .
> To post to this group, send email to django-d...@googlegroups.com 
> .
> Visit this group at http://groups.google.com/group/django-developers.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-developers/CAPDLAU7bYbeYb7pRgmqTR--zUrdU0fJyB5mHPWHoGEgawbB-MA%40mail.gmail.com
>  
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>  

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/50e5a810-66d5-434a-b202-c19a2379f985%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


ForeignObject defaults to virtual_only=False?

2015-07-14 Thread Tim Graham
ForeignObject defaults to virtual_only=False [1]. This seems 
counterintuitive as my understanding is that ForeignObject fields are 
virtual (i.e. they don't directly map to a database column).

I am testing Andrew's patch to allow disabling migrations in tests [2] and 
ran into a problem in Django's test suite because of this. For models with 
ForeignObject fields [3], these fields appear in model._meta.local_fields 
and so are added to migrations which raises an exception because 
field.column is None. I tried changing ForeignObject to default to 
virtual_only=True (and kept ForeignKey virtual_only=False), but there were 
non-trivial test failures, so I wanted to check my understanding before 
going down a wormhole.

My experimental branch is https://github.com/django/django/pull/4997

[1] 
https://github.com/django/django/blob/b356dc4e07915521db1e768d6357e3d982877a6e/django/db/models/fields/related.py#L1830-L1832
[2] https://github.com/django/django/pull/4986
[3] 
https://github.com/django/django/blob/b356dc4e07915521db1e768d6357e3d982877a6e/tests/foreign_object/models.py#L60-L68

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/e88f0124-ba52-4b21-8825-ae73824f1040%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: And again about permission to view

2015-07-14 Thread Григорий Крамаренко
Then lost the meaning: it is to give the ability to set custom permissions 
for all third-party applications whose code is "not available".

четверг, 9 июля 2015 г., 21:02:08 UTC+10 пользователь Tim Graham написал:
>
> Historically there's been pushback against adding new settings. That said, 
> I don't see an alternative here besides perhaps an AppConfig attribute 
> (last discussed in 
> https://groups.google.com/d/topic/django-developers/qnnCLppwA3o/discussion). 
> Perhaps we should try to move the existing auth settings to the AppConfig 
> and see if that works. I guess it won't be a trivial effort though, and not 
> sure it should block new features like this.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/65beec42-a5d8-4bb4-8fff-debbe3edb9ee%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.