# Path: armada/exceptions/api_exceptions.py
# class ApiException(base.ArmadaBaseException):
# class ApiBaseException(ApiException):
# class ApiJsonException(ApiException):
# class ClientUnauthorizedError(ApiException):
# class ClientForbiddenError(ApiException):
# class ClientError(ApiException):
# 
# Path: armada/handlers/armada.py
# LOG = logging.getLogger(__name__)
# CONF = cfg.CONF
# class Armada(object):
#     def __init__(self,
#                  documents,
#                  disable_update_pre=False,
#                  disable_update_post=False,
#                  enable_chart_cleanup=False,
#                  dry_run=False,
#                  set_ovr=None,
#                  force_wait=False,
#                  timeout=0,
#                  tiller_host=None,
#                  tiller_port=None,
#                  tiller_namespace=None,
#                  values=None,
#                  target_manifest=None,
#                  k8s_wait_attempts=1,
#                  k8s_wait_attempt_sleep=1):
#     def find_release_chart(self, known_releases, name):
#     def pre_flight_ops(self):
#     def tag_cloned_repo(self, ch, repos):
#     def get_releases_by_status(self, status):
#     def sync(self):
#     def post_flight_ops(self):
#     def _test_chart(self, release_name, timeout):
#     def show_diff(self, chart, installed_chart, installed_values, target_chart,
#                   target_values, msg):
#         def _sanitize_diff_str(str):


import yaml
from oslo_config import cfg
from oslo_log import log as logging
from armada.exceptions import api_exceptions as err
from armada.handlers.armada import Override
# Copyright 2017 The Armada Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is 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.




LOG = logging.getLogger(__name__)
CONF = cfg.CONF

API_VERSION = 'v{}/{}'


class ArmadaClient(object):
    def __init__(self, session):
        self.session = session


# Path: armada/exceptions/api_exceptions.py
# class ApiException(base.ArmadaBaseException):
# class ApiBaseException(ApiException):
# class ApiJsonException(ApiException):
# class ClientUnauthorizedError(ApiException):
# class ClientForbiddenError(ApiException):
# class ClientError(ApiException):
# 
# Path: armada/handlers/armada.py
# LOG = logging.getLogger(__name__)
# CONF = cfg.CONF
# class Armada(object):
#     def __init__(self,
#                  documents,
#                  disable_update_pre=False,
#                  disable_update_post=False,
#                  enable_chart_cleanup=False,
#                  dry_run=False,
#                  set_ovr=None,
#                  force_wait=False,
#                  timeout=0,
#                  tiller_host=None,
#                  tiller_port=None,
#                  tiller_namespace=None,
#                  values=None,
#                  target_manifest=None,
#                  k8s_wait_attempts=1,
#                  k8s_wait_attempt_sleep=1):
#     def find_release_chart(self, known_releases, name):
#     def pre_flight_ops(self):
#     def tag_cloned_repo(self, ch, repos):
#     def get_releases_by_status(self, status):
#     def sync(self):
#     def post_flight_ops(self):
#     def _test_chart(self, release_name, timeout):
#     def show_diff(self, chart, installed_chart, installed_values, target_chart,
#                   target_values, msg):
#         def _sanitize_diff_str(str):


# Path: armada/common/client.py
import yaml
from oslo_config import cfg
from oslo_log import log as logging
from armada.exceptions import api_exceptions as err
from armada.handlers.armada import Override

# Copyright 2017 The Armada Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is 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.




LOG = logging.getLogger(__name__)
CONF = cfg.CONF

API_VERSION = 'v{}/{}'


class ArmadaClient(object):
    def __init__(self, session):
        self.session = session


    def _set_endpoint(self, version, action):