Skip to content

Commit e6880a8

Browse files
authored
Merge pull request #42 from HBS-HBX/stack_trace_when_indexing_in_py3_#41
fix #41 stack trace when indexing in py3 and bump version to 0.7.7
2 parents 8657f71 + c870f0b commit e6880a8

File tree

4 files changed

+12
-2
lines changed

4 files changed

+12
-2
lines changed

CHANGELOG.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
Changelog
22
---------
33

4+
0.7.7 (2018-09-17)
5+
~~~~~~~~~~~~~~~~~~
6+
* fix `#41 stack trace when indexing in py3 <https://github.com/HBS-HBX/django-elastic-migrations/issues/41>`_
7+
48
0.7.6 (2018-09-11)
59
~~~~~~~~~~~~~~~~~~
610
* fix `#36 es_update --start flag broken <https://github.com/HBS-HBX/django-elastic-migrations/issues/39>`_

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -377,6 +377,12 @@ $ ./manage.py loaddata tests/myfixture.json
377377
Installed 101 object(s) from 1 fixture(s)
378378
```
379379
380+
There are already 100 films available using `loaddata` as follows:
381+
382+
```
383+
$ ./manage.py loaddata tests/100films.json
384+
```
385+
380386
### Running Tests Locally
381387
382388
Run `make test`. To run all tests and quality checks locally,

django_elastic_migrations/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
from django_elastic_migrations.utils import loading
1111
from django_elastic_migrations.utils.django_elastic_migrations_log import get_logger
1212

13-
__version__ = '0.7.6'
13+
__version__ = '0.7.7'
1414

1515
default_app_config = 'django_elastic_migrations.apps.DjangoElasticMigrationsConfig' # pylint: disable=invalid-name
1616

django_elastic_migrations/indexes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -579,7 +579,7 @@ def generate_batches(cls, qs=None, batch_size=BATCH_SIZE, total_items=None, upda
579579
try:
580580
qs_ids = list(qs.values_list(cls.PK_ATTRIBUTE, flat=True))
581581
except TypeError as e:
582-
if "values_list() got an unexpected keyword argument 'flat'" in e:
582+
if "values_list() got an unexpected keyword argument 'flat'" in str(e):
583583
qs_ids = [str(id) for id in list(qs.values_list(cls.PK_ATTRIBUTE))]
584584
else:
585585
raise

0 commit comments

Comments
 (0)