Update to work with neutronclient 2.3.12
Change-Id: I2e2de42b3c367430509de9eb31eddb0cb5a568e3
This commit is contained in:
		@@ -15,8 +15,8 @@ import logging
 | 
				
			|||||||
import string
 | 
					import string
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from neutronclient.common import utils
 | 
					from neutronclient.common import utils
 | 
				
			||||||
 | 
					from neutronclient.i18n import _
 | 
				
			||||||
from neutronclient.neutron import v2_0 as neutronV20
 | 
					from neutronclient.neutron import v2_0 as neutronV20
 | 
				
			||||||
from neutronclient.openstack.common.gettextutils import _
 | 
					 | 
				
			||||||
from oslo.serialization import jsonutils
 | 
					from oslo.serialization import jsonutils
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -22,8 +22,8 @@ import string
 | 
				
			|||||||
from heatclient.common import template_utils
 | 
					from heatclient.common import template_utils
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from neutronclient.common import exceptions as exc
 | 
					from neutronclient.common import exceptions as exc
 | 
				
			||||||
 | 
					from neutronclient.i18n import _
 | 
				
			||||||
from neutronclient.neutron import v2_0 as neutronV20
 | 
					from neutronclient.neutron import v2_0 as neutronV20
 | 
				
			||||||
from neutronclient.openstack.common.gettextutils import _
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
class ListServiceChainInstance(neutronV20.ListCommand):
 | 
					class ListServiceChainInstance(neutronV20.ListCommand):
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -27,6 +27,7 @@ from keystoneclient.auth.identity import v3 as v3_auth
 | 
				
			|||||||
from keystoneclient import discover
 | 
					from keystoneclient import discover
 | 
				
			||||||
from keystoneclient.openstack.common.apiclient import exceptions as ks_exc
 | 
					from keystoneclient.openstack.common.apiclient import exceptions as ks_exc
 | 
				
			||||||
from keystoneclient import session
 | 
					from keystoneclient import session
 | 
				
			||||||
 | 
					from oslo.utils import encodeutils
 | 
				
			||||||
import six.moves.urllib.parse as urlparse
 | 
					import six.moves.urllib.parse as urlparse
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from cliff import app
 | 
					from cliff import app
 | 
				
			||||||
@@ -34,8 +35,7 @@ from cliff import commandmanager
 | 
				
			|||||||
from neutronclient.common import clientmanager
 | 
					from neutronclient.common import clientmanager
 | 
				
			||||||
from neutronclient.common import exceptions as exc
 | 
					from neutronclient.common import exceptions as exc
 | 
				
			||||||
from neutronclient.common import utils
 | 
					from neutronclient.common import utils
 | 
				
			||||||
from neutronclient.openstack.common.gettextutils import _
 | 
					from neutronclient.i18n import _
 | 
				
			||||||
from neutronclient.openstack.common import strutils
 | 
					 | 
				
			||||||
from neutronclient.version import __version__
 | 
					from neutronclient.version import __version__
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from gbpclient.gbp.v2_0 import groupbasedpolicy as gbp
 | 
					from gbpclient.gbp.v2_0 import groupbasedpolicy as gbp
 | 
				
			||||||
@@ -831,7 +831,7 @@ class GBPShell(app.App):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
def main(argv=sys.argv[1:]):
 | 
					def main(argv=sys.argv[1:]):
 | 
				
			||||||
    try:
 | 
					    try:
 | 
				
			||||||
        return GBPShell(NEUTRON_API_VERSION).run(map(strutils.safe_decode,
 | 
					        return GBPShell(NEUTRON_API_VERSION).run(map(encodeutils.safe_decode,
 | 
				
			||||||
                                                     argv))
 | 
					                                                     argv))
 | 
				
			||||||
    except exc.NeutronClientException:
 | 
					    except exc.NeutronClientException:
 | 
				
			||||||
        return 1
 | 
					        return 1
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -33,7 +33,7 @@ from keystoneclient import session
 | 
				
			|||||||
from neutronclient import client
 | 
					from neutronclient import client
 | 
				
			||||||
from neutronclient.common import exceptions
 | 
					from neutronclient.common import exceptions
 | 
				
			||||||
from neutronclient.common import utils
 | 
					from neutronclient.common import utils
 | 
				
			||||||
from neutronclient.openstack.common import jsonutils
 | 
					from oslo_serialization import jsonutils
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
USERNAME = 'testuser'
 | 
					USERNAME = 'testuser'
 | 
				
			||||||
@@ -450,7 +450,7 @@ class CLITestAuthKeystone(testtools.TestCase):
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        self.assertRaises(
 | 
					        self.assertRaises(
 | 
				
			||||||
            ks_exceptions.EndpointNotFound,
 | 
					            ks_exceptions.EndpointNotFound,
 | 
				
			||||||
            self.client.authenticate)
 | 
					            getattr, self.client, 'endpoint_url')
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def test_strip_credentials_from_log(self):
 | 
					    def test_strip_credentials_from_log(self):
 | 
				
			||||||
        def verify_no_credentials(kwargs):
 | 
					        def verify_no_credentials(kwargs):
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -16,11 +16,11 @@ import time
 | 
				
			|||||||
import urllib
 | 
					import urllib
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from neutronclient import client
 | 
					from neutronclient import client
 | 
				
			||||||
from neutronclient.common import _
 | 
					 | 
				
			||||||
from neutronclient.common import constants
 | 
					from neutronclient.common import constants
 | 
				
			||||||
from neutronclient.common import exceptions
 | 
					from neutronclient.common import exceptions
 | 
				
			||||||
from neutronclient.common import serializer
 | 
					from neutronclient.common import serializer
 | 
				
			||||||
from neutronclient.common import utils
 | 
					from neutronclient.common import utils
 | 
				
			||||||
 | 
					from neutronclient.i18n import _
 | 
				
			||||||
import requests
 | 
					import requests
 | 
				
			||||||
import six.moves.urllib.parse as urlparse
 | 
					import six.moves.urllib.parse as urlparse
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -737,14 +737,11 @@ class Client(object):
 | 
				
			|||||||
        if type(params) is dict and params:
 | 
					        if type(params) is dict and params:
 | 
				
			||||||
            params = utils.safe_encode_dict(params)
 | 
					            params = utils.safe_encode_dict(params)
 | 
				
			||||||
            action += '?' + urllib.urlencode(params, doseq=1)
 | 
					            action += '?' + urllib.urlencode(params, doseq=1)
 | 
				
			||||||
        # Ensure client always has correct uri - do not guesstimate anything
 | 
					 | 
				
			||||||
        self.httpclient.authenticate_and_fetch_endpoint_url()
 | 
					 | 
				
			||||||
        self._check_uri_length(action)
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if body:
 | 
					        if body:
 | 
				
			||||||
            body = self.serialize(body)
 | 
					            body = self.serialize(body)
 | 
				
			||||||
        self.httpclient.content_type = self.content_type()
 | 
					        resp, replybody = self.httpclient.do_request(
 | 
				
			||||||
        resp, replybody = self.httpclient.do_request(action, method, body=body)
 | 
					            action, method, body=body, content_type=self.content_type())
 | 
				
			||||||
        status_code = resp.status_code
 | 
					        status_code = resp.status_code
 | 
				
			||||||
        if status_code in (requests.codes.ok,
 | 
					        if status_code in (requests.codes.ok,
 | 
				
			||||||
                           requests.codes.created,
 | 
					                           requests.codes.created,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,7 +1,5 @@
 | 
				
			|||||||
# The order of packages is significant, because pip processes them in the order
 | 
					# The order of packages is significant, because pip processes them in the order
 | 
				
			||||||
# of appearance. Changing the order has an impact on the overall integration
 | 
					# of appearance. Changing the order has an impact on the overall integration
 | 
				
			||||||
# process, which may cause wedges in the gate later.
 | 
					# process, which may cause wedges in the gate later.
 | 
				
			||||||
oslo.serialization>=1.2.0,<1.5  # uncapped by python-heatclient-0.3.0
 | 
					python-heatclient>=0.2.9,<0.3.0
 | 
				
			||||||
oslo.i18n>=1.3.0,<1.6  # uncapped by python-heatclient-0.3.0
 | 
					python-neutronclient==2.3.12
 | 
				
			||||||
python-heatclient>=0.2.9,<0.4
 | 
					 | 
				
			||||||
python-neutronclient>=2.3.0,<2.3.10
 | 
					 | 
				
			||||||
 
 | 
				
			|||||||
@@ -3,16 +3,16 @@
 | 
				
			|||||||
# process, which may cause wedges in the gate later.
 | 
					# process, which may cause wedges in the gate later.
 | 
				
			||||||
hacking>=0.8.0,<0.9
 | 
					hacking>=0.8.0,<0.9
 | 
				
			||||||
 | 
					
 | 
				
			||||||
cliff-tablib>=1.0
 | 
					cliff-tablib<=1.1,>=1.0
 | 
				
			||||||
coverage>=3.6
 | 
					coverage<=3.7.1,>=3.6
 | 
				
			||||||
discover
 | 
					discover<=0.4.0
 | 
				
			||||||
fixtures>=0.3.14
 | 
					fixtures<=1.0.0,>=0.3.14
 | 
				
			||||||
httpretty>=0.8.0,!=0.8.1,!=0.8.2,!=0.8.3
 | 
					httpretty>=0.8.0,!=0.8.1,!=0.8.2,!=0.8.3
 | 
				
			||||||
mox3>=0.7.0
 | 
					mox3<=0.7.0,>=0.7.0
 | 
				
			||||||
oslosphinx>=2.2.0.0a2
 | 
					oslosphinx<2.5.0,>=2.2.0 # Apache-2.0
 | 
				
			||||||
oslotest>=1.1.0.0a2
 | 
					oslotest<1.4.0,>=1.1.0 # Apache-2.0
 | 
				
			||||||
python-subunit>=0.0.18
 | 
					python-subunit<=1.0.0,>=0.0.18
 | 
				
			||||||
sphinx>=1.1.2,!=1.2.0,<1.3
 | 
					requests-mock>=0.4.0 # Apache-2.0
 | 
				
			||||||
testrepository>=0.0.18
 | 
					sphinx!=1.2.0,<1.3,>=1.1.2
 | 
				
			||||||
testscenarios>=0.4
 | 
					testrepository<=0.0.20,>=0.0.18
 | 
				
			||||||
testtools>=0.9.34
 | 
					testtools!=1.4.0,<=1.5.0,>=0.9.34
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user