Skip to content

Commit

Permalink
Also wipe when recreating alias from existing index
Browse files Browse the repository at this point in the history
  • Loading branch information
KevinMind committed Nov 5, 2024
1 parent e229395 commit c78bab5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/olympia/amo/management/commands/initialize.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,4 @@ def handle(self, *args, **options):
# We should reindex even if no data is loaded/modified
# because we might have a fresh instance of elasticsearch
else:
call_command('reindex', '--noinput', '--skip-if-exists')
call_command('reindex', '--wipe', '--noinput', '--skip-if-exists')
4 changes: 3 additions & 1 deletion src/olympia/amo/tests/test_commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,9 @@ class Commands:

flush = mock.call('flush', '--noinput')
reindex_force_wipe = mock.call('reindex', '--wipe', '--force', '--noinput')
reindex_skip_if_exists = mock.call('reindex', '--noinput', '--skip-if-exists')
reindex_skip_if_exists = mock.call(
'reindex', '--wipe', '--noinput', '--skip-if-exists'
)
load_initial_data = mock.call('loaddata', 'initial.json')
import_prod_versions = mock.call('import_prod_versions')
createsuperuser = mock.call(
Expand Down

0 comments on commit c78bab5

Please sign in to comment.