Skip to content

remove the very last reference to "six" #9286

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion awscli/argprocess.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@
# language governing permissions and limitations under the License.
"""Module for processing CLI args."""

import json
import logging
import os
from collections import OrderedDict

from botocore.compat import OrderedDict, json
from botocore.utils import is_json_value_header

from awscli import COMPLEX_TYPES, SCALAR_TYPES, shorthand
Expand Down
2 changes: 1 addition & 1 deletion awscli/bcdoc/restdoc.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
import logging
from collections import OrderedDict

from botocore.compat import OrderedDict
from awscli.bcdoc.docstringparser import DocStringParser
from awscli.bcdoc.style import ReSTStyle

Expand Down
3 changes: 2 additions & 1 deletion awscli/clidriver.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,10 @@
import logging
import signal
import sys
from collections import OrderedDict

import botocore.session
from botocore.compat import OrderedDict, copy_kwargs
from botocore.compat import copy_kwargs
from botocore.exceptions import (
NoCredentialsError,
NoRegionError,
Expand Down
3 changes: 1 addition & 2 deletions awscli/compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,11 @@
import shlex
import signal
import urllib.parse as urlparse
from collections import OrderedDict
from configparser import RawConfigParser
from urllib.error import URLError
from urllib.request import urlopen

from botocore.compat import six, OrderedDict

import sys
import zipfile
from functools import partial
Expand Down
4 changes: 2 additions & 2 deletions awscli/customizations/cloudformation/yamlhelper.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
from botocore.compat import json
from botocore.compat import OrderedDict
import json
from collections import OrderedDict

import yaml
from yaml.resolver import ScalarNode, SequenceNode
Expand Down
2 changes: 1 addition & 1 deletion awscli/customizations/cloudsearch.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
# language governing permissions and limitations under the License.

import logging
from collections import OrderedDict

from awscli.customizations.flatten import FlattenArguments, SEP
from botocore.compat import OrderedDict

LOG = logging.getLogger(__name__)

Expand Down
2 changes: 1 addition & 1 deletion awscli/customizations/commands.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import logging
import os
from collections import OrderedDict

from botocore import model
from botocore.compat import OrderedDict
from botocore.validate import validate_parameters

import awscli
Expand Down
2 changes: 1 addition & 1 deletion awscli/customizations/eks/kubeconfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
import yaml
import logging
import errno
from botocore.compat import OrderedDict
from collections import OrderedDict

from awscli.customizations.eks.exceptions import EKSError
from awscli.customizations.eks.ordered_yaml import (ordered_yaml_load,
Expand Down
3 changes: 2 additions & 1 deletion awscli/customizations/eks/ordered_yaml.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.

from collections import OrderedDict

import yaml
from botocore.compat import OrderedDict


class SafeOrderedLoader(yaml.SafeLoader):
Expand Down
3 changes: 1 addition & 2 deletions awscli/customizations/eks/update_kubeconfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@

import os
import logging

from botocore.compat import OrderedDict
from collections import OrderedDict

from awscli.customizations.commands import BasicCommand
from awscli.customizations.utils import uni_print
Expand Down
3 changes: 2 additions & 1 deletion awscli/customizations/emr/createcluster.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.

import json
import re

from awscli.customizations.commands import BasicCommand
from awscli.customizations.emr import applicationutils
from awscli.customizations.emr import argumentschema
Expand All @@ -27,7 +29,6 @@
from awscli.customizations.emr.command import Command
from awscli.customizations.emr.constants import EC2_ROLE_NAME
from awscli.customizations.emr.constants import EMR_ROLE_NAME
from botocore.compat import json


class CreateCluster(Command):
Expand Down
3 changes: 2 additions & 1 deletion awscli/customizations/emr/emrfsutils.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,11 @@
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.

from collections import OrderedDict

from awscli.customizations.emr import constants
from awscli.customizations.emr import emrutils
from awscli.customizations.emr import exceptions
from botocore.compat import OrderedDict


CONSISTENT_OPTIONAL_KEYS = ['RetryCount', 'RetryPeriod']
Expand Down
2 changes: 1 addition & 1 deletion awscli/customizations/servicecatalog/generateproduct.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.

import json
import sys

from awscli.customizations.servicecatalog import helptext
from awscli.customizations.servicecatalog.generatebase \
import GenerateBaseCommand
from botocore.compat import json


class GenerateProductCommand(GenerateBaseCommand):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.

import json
import sys

from awscli.customizations.servicecatalog import helptext
from awscli.customizations.servicecatalog.generatebase \
import GenerateBaseCommand
from botocore.compat import json


class GenerateProvisioningArtifactCommand(GenerateBaseCommand):
Expand Down
2 changes: 1 addition & 1 deletion awscli/formatter.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
import json
import logging

from botocore.compat import json
from botocore.paginate import PageIterator
from botocore.utils import set_value_from_jmespath

Expand Down
3 changes: 1 addition & 2 deletions tests/functional/eks/test_kubeconfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@
import os
import shutil
import tempfile

from botocore.compat import OrderedDict
from collections import OrderedDict

from awscli.testutils import mock, unittest
from tests.functional.eks.test_util import get_testdata
Expand Down
5 changes: 2 additions & 3 deletions tests/unit/customizations/cloudformation/test_yamlhelper.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,9 @@
# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
import json
import tempfile

from botocore.compat import json
from botocore.compat import OrderedDict
from collections import OrderedDict

from awscli.testutils import mock, unittest
from awscli.customizations.cloudformation.deployer import Deployer
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import json

import pytest

import awscli.customizations.datapipeline.createdefaultroles \
Expand All @@ -11,7 +13,6 @@
from awscli.testutils import BaseAWSCommandParamsTest,\
mock, unittest
from awscli.customizations.datapipeline.translator import dict_to_string
from botocore.compat import json


@pytest.mark.filterwarnings('ignore::UserWarning')
Expand Down
5 changes: 3 additions & 2 deletions tests/unit/customizations/datapipeline/test_translator.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,13 @@
# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
import json
from collections import OrderedDict

from awscli.customizations.datapipeline.translator \
import PipelineDefinitionError
from awscli.testutils import unittest

from botocore.compat import OrderedDict, json

from awscli.customizations.datapipeline import translator


Expand Down
3 changes: 2 additions & 1 deletion tests/unit/customizations/dlm/test_create_default_role.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@
# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
import json

from awscli.testutils import BaseAWSCommandParamsTest, mock, unittest
from botocore.compat import json
import botocore.session
from awscli.customizations.dlm.iam import IAM

Expand Down
2 changes: 1 addition & 1 deletion tests/unit/customizations/eks/test_kubeconfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
import os
import tempfile
import shutil
from botocore.compat import OrderedDict
from collections import OrderedDict

from awscli.testutils import mock, unittest, skip_if_windows
from awscli.customizations.utils import uni_print
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/customizations/eks/test_update_kubeconfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
import sys
import tempfile
from argparse import Namespace
from collections import OrderedDict

import botocore
from botocore.compat import OrderedDict

import awscli.customizations.eks.kubeconfig as kubeconfig
from awscli.customizations.eks.exceptions import EKSClusterError, EKSError
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,9 @@
# language governing permissions and limitations under the License.

import copy
import json
import os

from botocore.compat import json
from botocore.compat import OrderedDict
from collections import OrderedDict

from tests.unit.customizations.emr import test_constants as \
CONSTANTS
Expand Down
3 changes: 2 additions & 1 deletion tests/unit/customizations/emr/test_create_default_role.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
from botocore.compat import json
import json

from botocore.awsrequest import AWSResponse
from botocore.exceptions import ClientError

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.

import json
from argparse import Namespace

from awscli.customizations.servicecatalog import exceptions
from awscli.customizations.servicecatalog.generateproduct \
import GenerateProductCommand
from awscli.testutils import unittest, mock, capture_output
from botocore.compat import json


class TestCreateProductCommand(unittest.TestCase):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.

import json
from argparse import Namespace

from awscli.customizations.servicecatalog import exceptions
from awscli.customizations.servicecatalog.generateprovisioningartifact \
import GenerateProvisioningArtifactCommand
from awscli.testutils import unittest, mock, capture_output
from botocore.compat import json


class TestCreateProvisioningArtifactCommand(unittest.TestCase):
Expand Down
4 changes: 2 additions & 2 deletions tests/unit/output/test_json_output.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@
# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
from botocore.compat import json
import json
import platform
from awscli.formatter import JSONFormatter

from awscli.formatter import JSONFormatter
from awscli.testutils import BaseAWSCommandParamsTest, unittest
from awscli.testutils import mock, skip_if_windows
from awscli.compat import StringIO, get_stdout_text_writer
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/test_argprocess.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
import json
from collections import OrderedDict

from botocore import xform_name
from botocore import model
from botocore.compat import OrderedDict

from awscli.testutils import mock
from awscli.testutils import unittest
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/test_clidriver.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@
import io
import sys
import importlib
from collections import OrderedDict

from botocore.awsrequest import AWSResponse
from botocore.exceptions import NoCredentialsError
from botocore.compat import OrderedDict
import botocore.model

import awscli
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/test_completer.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
# language governing permissions and limitations under the License.
import pprint
import difflib
from collections import OrderedDict

from botocore.compat import OrderedDict
from botocore.model import OperationModel
from awscli.clidriver import (
CLIDriver, ServiceCommand, ServiceOperation, CLICommand)
Expand Down
3 changes: 1 addition & 2 deletions tests/unit/test_schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@
# ANY KIND, either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
import pprint

from botocore.compat import OrderedDict
from collections import OrderedDict

from awscli.testutils import unittest
from awscli.schema import ParameterRequiredError, SchemaTransformer
Expand Down