Re: In-memory queryset

2017-03-08 Thread Neal Todd
Hi Paul, Depending on your use cases django-modelcluster might be of some use: https://github.com/wagtail/django-modelcluster It's primarly for dealing with a bunch of models that have foreign key relationships, but before they're written to a database (i.e before they have primary keys that a

Re: In-memory queryset

2017-03-07 Thread Tim Chase
On 2017-03-07 07:17, Jacob Kaplan-Moss wrote: > It's certainly _possible_ to implement a in-memory datastore, and > it might be pretty useful. It's just pretty dang hard to do more > than the first 20% or so. Would there also be issues with WSGI spinning up/down various Django processes? Any in-m

Re: In-memory queryset

2017-03-07 Thread Jacob Kaplan-Moss
Hey Paul - There are a couple of implementations I'm aware of: https://github.com/stphivos/django-mock-queries https://github.com/dcramer/mock-django Neither are a complete implementation of the QuerySet API, and I think this is because the QuerySet API surface is _huge_. Implementing the entire

Re: In-memory queryset

2017-03-07 Thread ludovic coues
This look like a question for django user. The QuerySet API is only an abstraction layer to SQL code. That's why it require a database. If you really don't want to store your object on a filesystem, sqlite support database living only in memory. That's mainly for testing purpose but that could fit

In-memory queryset

2017-03-07 Thread paul
Hi, It would be really convenient for me if there was an implementation of the QuerySet API which instead of using a database as its data source, used in-memory model instance that had not been persisted to the database at all. I looked around and found nothing like this. Is this because nothi