Re: Adding Support for a Float32 Field

2017-02-26 Thread Florian Apolloner
On Monday, February 27, 2017 at 6:50:27 AM UTC+1, Daniel da Silva wrote: > > I'm not sure of the design rationale behind including options to specify > variants of integers, but not floats. We already have SmallIntegerField, > IntegerField, and BigIntegerField. Why is this not in the same line of

Re: Adding Support for a Float32 Field

2017-02-26 Thread Daniel da Silva
I'm not sure of the design rationale behind including options to specify variants of integers, but not floats. We already have SmallIntegerField, IntegerField, and BigIntegerField. Why is this not in the same line of thinking? I might as well justify my use case a little more: I am building a

Feature Request AND/OR Documentation Fix: Manager.from_queryset does not copy methods that already exist even with queryset_only=False

2017-02-26 Thread Dylan Young
Bug: This behaviour should be documented, as it means that certain methods can't be specified in the a QuerySet subclass and be expected to be copied into the corresponding Manager: ``get_queryset`` and ``all``, in particular. Docs: - Methods with a queryset_only attribute set to False are al

Re: Adding Support for a Float32 Field

2017-02-26 Thread Adam Johnson
> > Personally I do not see much need for it in core. Same, it's not hard to implement as a custom field in a third party plugin. Another point is that this isn't supported by SQLite - it only has "REAL" meaning a double precision. On 26 February 2017 at 16:21, Florian Apolloner wrote: > Pers

Re: Adding Support for a Float32 Field

2017-02-26 Thread Florian Apolloner
Personally I do not see much need for it in core. > If I switched to single precision, I could cut the storage size of my database in half with no loss of information. Can you elaborate more on that? For it to be able to be usable you most likely at least have also a serial field (which is anot

Adding Support for a Float32 Field

2017-02-26 Thread Daniel da Silva
I have a Django project that uses the database to store a large number of sensor readings. I use FloatField to store these, which maps to a double precision float in the database. This is a waste of space, because the sensors themselves are only accurately to a few decimal places. If I switched

Re: Template handling of undefined variables

2017-02-26 Thread Florian Apolloner
As much as I'd like variables to raise an error if they cannot resolve, I am with Karen here -- the backwards compatibility considerations should take priority here. At least we should have a possibility in the templates to check if variables are undefined before we start raising exceptions. Ch