ChristopherRabotin / bungiesearch

UNMAINTAINED CODE -- Elasticsearch-dsl-py django wrapper with mapping generator
BSD 3-Clause "New" or "Revised" License
68 stars 20 forks source link

Indexing a None value may index it as a string #73

Closed ChristopherRabotin closed 9 years ago

ChristopherRabotin commented 9 years ago

At least in some instances, it seems that indexing a None value will index it as None: the missing filter does not filter them out.

In [69]: Article.objects.bungie_allcontent().index('sparrho').filter('missing', field='created').sort('created').count()
Out[69]: 0
In [70]: article = Article.objects.bungie_allcontent().index('sparrho').sort('created')[:1:True]
In [71]: article.created is None
Out[71]: True