diff --git a/couchdb_cluster_admin/describe.py b/couchdb_cluster_admin/describe.py index 79d4f6a3ee..f4723fa52c 100644 --- a/couchdb_cluster_admin/describe.py +++ b/couchdb_cluster_admin/describe.py @@ -9,7 +9,6 @@ get_shard_allocation, indent, ) -from six.moves import map def print_shard_table(shard_allocation_docs): diff --git a/couchdb_cluster_admin/doc_models.py b/couchdb_cluster_admin/doc_models.py index 7743130b7a..7f80828425 100644 --- a/couchdb_cluster_admin/doc_models.py +++ b/couchdb_cluster_admin/doc_models.py @@ -1,8 +1,6 @@ from __future__ import absolute_import from collections import defaultdict from jsonobject import JsonObject, ListProperty, DictProperty, StringProperty, IntegerProperty -from six.moves import map -import six class ConfigInjectionMixin(object): @@ -22,8 +20,8 @@ def set_config(self, config): class MembershipDoc(ConfigInjectionMixin, JsonObject): _allow_dynamic_properties = False - cluster_nodes = ListProperty(six.text_type, required=True) - all_nodes = ListProperty(six.text_type, required=True) + cluster_nodes = ListProperty(str, required=True) + all_nodes = ListProperty(str, required=True) def get_printable(self): return ( @@ -41,10 +39,10 @@ class ShardAllocationDoc(ConfigInjectionMixin, JsonObject): _id = StringProperty() _rev = StringProperty(exclude_if_none=True) - by_node = DictProperty(ListProperty(six.text_type)) - changelog = ListProperty(ListProperty(six.text_type)) + by_node = DictProperty(ListProperty(str)) + changelog = ListProperty(ListProperty(str)) shard_suffix = ListProperty(int) - by_range = DictProperty(ListProperty(six.text_type)) + by_range = DictProperty(ListProperty(str)) @property def usable_shard_suffix(self): @@ -126,6 +124,6 @@ def get_printable(self, include_shard_names=True, db_name_len=20): class AllocationSpec(JsonObject): - databases = ListProperty(six.text_type) - nodes = ListProperty(six.text_type) + databases = ListProperty(str) + nodes = ListProperty(str) copies = IntegerProperty() diff --git a/couchdb_cluster_admin/suggest_shard_allocation.py b/couchdb_cluster_admin/suggest_shard_allocation.py index eac52a3bec..6eb0b253c8 100644 --- a/couchdb_cluster_admin/suggest_shard_allocation.py +++ b/couchdb_cluster_admin/suggest_shard_allocation.py @@ -12,7 +12,6 @@ from .describe import print_shard_table from .file_plan import read_plan_file from .doc_models import ShardAllocationDoc, AllocationSpec -from six.moves import range class _NodeAllocation(object): diff --git a/couchdb_cluster_admin/utils.py b/couchdb_cluster_admin/utils.py index 16d15118eb..3aa6855d61 100644 --- a/couchdb_cluster_admin/utils.py +++ b/couchdb_cluster_admin/utils.py @@ -12,9 +12,6 @@ from requests import HTTPError from .doc_models import MembershipDoc, ShardAllocationDoc -import six -from six.moves import range -from six.moves import input NodeDetails = namedtuple('NodeDetails', 'ip port node_local_port couchdb_version username password socks_port') @@ -133,7 +130,7 @@ class Config(JsonObject): control_node_local_port = IntegerProperty() couchdb_version = StringProperty() username = StringProperty() - aliases = DictProperty(six.text_type) + aliases = DictProperty(str) def set_password(self, password): self._password = password diff --git a/requirements.txt b/requirements.txt index e394a4364b..60a04caea5 100644 --- a/requirements.txt +++ b/requirements.txt @@ -24,7 +24,5 @@ pyyaml==6.0.2 # via couchdb-cluster-admin (setup.py) requests==2.27.1 # via couchdb-cluster-admin (setup.py) -six==1.12.0 - # via jsonobject urllib3==1.26.5 # via requests