Skip to content

Commit

Permalink
Merge pull request #34 from HBS-HBX/#33_error_when_nothing_to_resume
Browse files Browse the repository at this point in the history
fix #33 error when nothing to resume
  • Loading branch information
codekiln authored Aug 16, 2018
2 parents ec1b244 + a1b2a66 commit eb433b9
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
Changelog
---------

0.7.4 (2018-08-15)
~~~~~~~~~~~~~~~~~~
* fix #33 error when nothing to resume using --resume

0.7.3 (2018-08-14)
~~~~~~~~~~~~~~~~~~
* fix #31 es_update movies --newer --workers does not store worker information
Expand Down
2 changes: 1 addition & 1 deletion django_elastic_migrations/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from django_elastic_migrations.utils import loading
from django_elastic_migrations.utils.django_elastic_migrations_log import get_logger

__version__ = '0.7.3'
__version__ = '0.7.4'

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

Expand Down
5 changes: 3 additions & 2 deletions django_elastic_migrations/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -1014,12 +1014,13 @@ def perform_action(self, dem_index, *args, **kwargs):
)
elif self.resume_mode:
self._last_update = self.index_version.get_last_time_update_called(before_action=self)
self._last_update_phrase = self._last_update
if not self._last_update:
self._last_update = 'never'
self._last_update_phrase = 'never'
self.add_log(
"--resume: checking the last time update was called succesfully and completed: "
u"\n - index version: {_index_version_name} "
u"\n - update date: {_last_update} ", use_self_dict_format=True
u"\n - update date: {_last_update_phrase} ", use_self_dict_format=True
)

self.add_log("Starting batched bulk update ...")
Expand Down

0 comments on commit eb433b9

Please sign in to comment.