Re: Improving Test Speed for Projects that use django.contrib.postgres

2015-05-04 Thread Curtis Maloney
I looked into using UNLOGGED some time ago, but the create table method was misnamed, and the actual create table function was inflexible. Now the code is much cleaner, and each DB can specify how to enact create table and friends. Which leaves us with the question -- is it possible to alter the

Re: Improving Test Speed for Projects that use django.contrib.postgres

2015-05-04 Thread Aymeric Augustin
2015-05-05 6:15 GMT+02:00 David Muller : > Haven't had a chance to try and throw everything into RAM disk but that > sounds pretty cool. > Actually, that's the reason why I added support for tablespaces on PostgreSQL in Django 1.4 :-) https://docs.djangoproject.com/en/1.8/ref/settings/#default-t

Re: Improving Test Speed for Projects that use django.contrib.postgres

2015-05-04 Thread David Muller
Thanks for the helpful advice, Marc. I toyed with my settings a bit (especially the memory ones -- upping shared_buffers, work_mem and effective_cache_size) to be in line with the suggestions in Christophe Pettus' talk , but did not observe

Re: URL dispatcher API

2015-05-04 Thread Carl Meyer
Hi Marten, On 05/04/2015 01:45 PM, Marten Kenbeek wrote: > I'd like to discuss the API I'm proposing for the new url dispatcher I'm > working on. I'll try to explain the API and some of the rationale behind it. Thanks for seeking comment early, and providing working PoC code, prose description, a

URL dispatcher API

2015-05-04 Thread Marten Kenbeek
Hi all, I'd like to discuss the API I'm proposing for the new url dispatcher I'm working on. I'll try to explain the API and some of the rationale behind it. There is a working proof-of-concept at https://github.com/knbk/django/tree/url_dispatcher. Currently, all the names are chosen as not to

Re: Improving Test Speed for Projects that use django.contrib.postgres

2015-05-04 Thread Marc Tamlyn
One of the main questions is to work out what is slow. You can often gain a lot by using the new --keep-db option which maintains the test database between runs meaning you don't have the DDL time each run. A brute force approach which can have an impact is to install postgres on a RAM disk, this

Improving Test Speed for Projects that use django.contrib.postgres

2015-05-04 Thread David Muller
Hi everybody, Recently I've begun to use the PostgreSQL specific fields introduced in Django 1.8. My codebase actually uses the special fields (HStoreField and ArrayField mostly) frequently enough such that I cannot run my test suite on an in memory SQLite database -- I have to run on a Postgr

Re: CSRF_COOKIE_HTTPONLY is misleading and not useful

2015-05-04 Thread Gavin Wahl
> How so? You cannot just ajax-fetch stuff from different domains. I'm talking about a single domain. Injected javascript on a page that doesn't contain the CSRF token can fetch a different page on the same domain to get it. > If you already injected javascript onto the victims page (XSS) there i

Re: CSRF_COOKIE_HTTPONLY is misleading and not useful

2015-05-04 Thread Florian Apolloner
On a second thought I think I missread what you wrote and you ment all of this within the scope of one domain and not from the perspective of an attacker. On Monday, May 4, 2015 at 1:58:19 PM UTC+2, Florian Apolloner wrote: > > On Monday, April 20, 2015 at 6:38:55 AM UTC+2, Gavin Wahl wrote: >>

Re: CSRF_COOKIE_HTTPONLY is misleading and not useful

2015-05-04 Thread Florian Apolloner
On Monday, April 20, 2015 at 6:38:55 AM UTC+2, Gavin Wahl wrote: > > > Though it could still ajax-in the token from a page that does have it, >> right? >> > > Exactly right. > How so? You cannot just ajax-fetch stuff from different domains. The usual security policies will forbid that. If you al