Skip to content

Commit

Permalink
Updates for 7.0.1 release (#1691)
Browse files Browse the repository at this point in the history
  • Loading branch information
untergeek authored Aug 16, 2023
1 parent fb0adf8 commit c4fb553
Show file tree
Hide file tree
Showing 11 changed files with 43 additions and 27 deletions.
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Dockerfile
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ html_docs/
index.html
msi_guid.txt
nosetests.xml
pytest.ini
samples
scratch
test/.DS_Store
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# syntax=docker/dockerfile:1
ARG PYVER=3.11.1
ARG PYVER=3.11.4
ARG ALPTAG=3.17
FROM python:${PYVER}-alpine${ALPTAG} as builder

Expand Down
2 changes: 1 addition & 1 deletion curator/_version.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
"""Curator Version"""
__version__ = '7.0.0'
__version__ = '7.0.1'
24 changes: 12 additions & 12 deletions curator/actions.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ def add(self, ilo, warn_if_no_indices=False):
# Add a warning if there are no indices to add, if so set in options
if warn_if_no_indices:
self.warn_if_no_indices = True
self.loggit.warn(
self.loggit.warning(
'No indices found after processing filters. '
'Nothing to add to {0}'.format(self.name)
)
Expand Down Expand Up @@ -91,7 +91,7 @@ def remove(self, ilo, warn_if_no_indices=False):
# Add a warning if there are no indices to add, if so set in options
if warn_if_no_indices:
self.warn_if_no_indices = True
self.loggit.warn(
self.loggit.warning(
'No indices found after processing filters. '
'Nothing to remove from {0}'.format(self.name)
)
Expand Down Expand Up @@ -326,7 +326,7 @@ def do_action(self):
self.client.indices.delete_alias(index=lst_as_csv, name='_all')
self.loggit.debug('Deleted aliases from: {0}'.format(lst))
except Exception as err:
self.loggit.warn(
self.loggit.warning(
'Some indices may not have had aliases. Exception:'
' {0}'.format(err)
)
Expand All @@ -337,7 +337,7 @@ def do_action(self):
if not self.ignore_sync_failures:
raise ConflictError(err.status_code, err.error, err.info)
else:
self.loggit.warn(
self.loggit.warning(
'Ignoring flushed sync failures: '
'{0} {1}'.format(err.error, err.info)
)
Expand Down Expand Up @@ -495,7 +495,7 @@ def do_action(self):
except RequestError as err:
match_list = ["index_already_exists_exception", "resource_already_exists_exception"]
if err.error in match_list and self.ignore_existing:
self.loggit.warn('Index %s already exists.' % self.name)
self.loggit.warning('Index %s already exists.' % self.name)
else:
raise exceptions.FailedExecution('Index %s already exists.' % self.name)
except Exception as err:
Expand Down Expand Up @@ -751,7 +751,7 @@ def _settings_check(self):
# Act here if the case is different for some settings.
pass
else:
self.loggit.warn(
self.loggit.warning(
'"{0}" is not a setting Curator recognizes and may or may '
'not work.'.format(k)
)
Expand Down Expand Up @@ -1518,7 +1518,7 @@ def do_action(self):
self._post_run_quick_check(dest, response['task'])

else:
self.loggit.warn(
self.loggit.warning(
'"wait_for_completion" set to {0}. Remember '
'to check task_id "{1}" for successful completion '
'manually.'.format(self.wfc, response['task'])
Expand Down Expand Up @@ -1682,7 +1682,7 @@ def do_action(self):
)
self.report_state()
else:
self.loggit.warn(
self.loggit.warning(
'"wait_for_completion" set to {0}.'
'Remember to check for successful completion '
'manually.'.format(self.wait_for_completion)
Expand Down Expand Up @@ -1752,7 +1752,7 @@ def __init__(
self.name = name if name else most_recent
# Stop here now, if it's not a successful snapshot.
if slo.snapshot_info[self.name]['state'] == 'PARTIAL' and partial:
self.loggit.warn(
self.loggit.warning(
'Performing restore of snapshot in state PARTIAL.')
elif slo.snapshot_info[self.name]['state'] != 'SUCCESS':
raise exceptions.CuratorException(
Expand Down Expand Up @@ -1918,7 +1918,7 @@ def do_action(self):
)
self.report_state()
else:
self.loggit.warn(
self.loggit.warning(
'"wait_for_completion" set to {0}. '
'Remember to check for successful completion '
'manually.'.format(self.wfc)
Expand Down Expand Up @@ -2061,7 +2061,7 @@ def _data_node(self, node_id):
self.loggit.info('Skipping node "{0}": master node'.format(name))
return False
elif 'master' in roles and self.node_filters['permit_masters']:
self.loggit.warn(
self.loggit.warning(
'Not skipping node "{0}" which is a master node (not recommended), but '
'permit_masters is True'.format(name)
)
Expand Down Expand Up @@ -2152,7 +2152,7 @@ def __log_action(self, error_msg, dry_run=False):
if not dry_run:
raise exceptions.ActionError(error_msg)
else:
self.loggit.warn('DRY-RUN: {0}'.format(error_msg))
self.loggit.warning('DRY-RUN: {0}'.format(error_msg))

def _block_writes(self, idx):
block = {'index.blocks.write': True}
Expand Down
4 changes: 2 additions & 2 deletions curator/indexlist.py
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ def _get_metadata(self):
wl['settings'] = alt_wl['settings']

if 'creation_date' not in wl['settings']['index']:
self.loggit.warn(
self.loggit.warning(
'Index: {0} has no "creation_date"! This implies '
'that the index predates Elasticsearch v1.4. For '
'safety, this index will be removed from the '
Expand Down Expand Up @@ -974,7 +974,7 @@ def filter_by_count(
for group in groups:
if use_age:
if source != 'name':
self.loggit.warn(
self.loggit.warning(
'Cannot get age information from closed indices unless '
'source="name". Omitting any closed indices.'
)
Expand Down
8 changes: 4 additions & 4 deletions curator/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -793,7 +793,7 @@ def process_auth_args(data):
password = data.pop('password', False)
if http_auth:
# No change to http_auth
LOGGER.warn(
LOGGER.warning(
'Use of "http_auth" is deprecated. Please use "username" and "password" instead.')
elif username and password:
http_auth = (username, password)
Expand Down Expand Up @@ -934,7 +934,7 @@ def do_version_check(client, skip):
Do a test of the Elasticsearch version, unless ``skip`` is ``True``
"""
if skip:
LOGGER.warn(
LOGGER.warning(
'Skipping Elasticsearch version verification. This is '
'acceptable for remote reindex operations.'
)
Expand Down Expand Up @@ -1699,13 +1699,13 @@ def snapshot_check(client, snapshot=None, repository=None):
LOGGER.info(
'Snapshot {0} successfully completed.'.format(snapshot))
elif state == 'PARTIAL':
LOGGER.warn(
LOGGER.warning(
'Snapshot {0} completed with state PARTIAL.'.format(snapshot))
elif state == 'FAILED':
LOGGER.error(
'Snapshot {0} completed with state FAILED.'.format(snapshot))
else:
LOGGER.warn(
LOGGER.warning(
'Snapshot {0} completed with state: {0}'.format(snapshot))
return True

Expand Down
14 changes: 14 additions & 0 deletions docs/Changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,20 @@
Changelog
=========

7.0.1 (16 August 2023)
----------------------

**Changes**

* This release brings some Python modules up to current releases, namely:
* ``certifi>=2023.5.7``
* ``click==8.1.4``
* ``elasticsearch7==7.17.9``
* ``pyyaml==6.0.1``
* The PyYAML change is notable as the Cython 3.0 upgrade caused it to no longer work.
Version 6.0.1 fixes that, enabling Curator to build again.
* ``cx_Freeze`` changed some configurations to be more Pythonic. #1681 fixes that.

7.0.0 (31 January 2023)
-----------------------

Expand Down
6 changes: 3 additions & 3 deletions docs/asciidoc/index.asciidoc
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
:curator_version: 7.0.0
:curator_version: 7.0.1
:curator_major: 7
:curator_doc_tree: 7.0
:es_py_version: 7.17.8
:es_py_version: 7.17.9
:es_doc_tree: 7.17
:stack_doc_tree: 7.17
:pybuild_ver: 3.11.1
:pybuild_ver: 3.11.4
:copyright_years: 2011-2023
:ref: http://www.elastic.co/guide/en/elasticsearch/reference/{es_doc_tree}
:esref: http://www.elastic.co/guide/en/elasticsearch/reference/{stack_doc_tree}
Expand Down
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ def get_version():

intersphinx_mapping = {
'python': ('https://docs.python.org/3.11', None),
'elasticsearch7': ('http://elasticsearch-py.readthedocs.io/en/7.17.8', None),
'elasticsearch7': ('http://elasticsearch-py.readthedocs.io/en/7.17.9', None),
}

autoclass_content = "both"
Expand Down
6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,14 @@ keywords = [
'index-expiry'
]
dependencies = [
"elasticsearch7==7.17.8",
"elasticsearch7==7.17.9",
"requests>=2.28.1",
"boto3>=1.24.54",
"requests_aws4auth>=1.1.2",
"click==8.1.3",
"click==8.1.4",
"pyyaml==6.0.1",
"voluptuous>=0.13.1",
"certifi>=2022.12.7",
"certifi>=2023.5.7",
"six>=1.16.0",
]

Expand Down

0 comments on commit c4fb553

Please sign in to comment.