diff --git a/nova_plugin/staccato_nova_download/__init__.py b/nova_plugin/staccato_nova_download/__init__.py index 3b2a0ab..6b0ca9d 100644 --- a/nova_plugin/staccato_nova_download/__init__.py +++ b/nova_plugin/staccato_nova_download/__init__.py @@ -93,7 +93,7 @@ class StaccatoTransfer(xfer_base.TransferBase): def download(self, context, url_parts, dst_file, metadata, **kwargs): LOG.info((_('Attemption to use %(module)s to download %(url)s')) % - {'module': unicode(self), 'url': url_parts.geturl()}) + {'module': unicode(self), 'url': url_parts.geturl()}) headers = {'Content-Type': 'application/json'} if CONF.auth_strategy == 'keystone': @@ -108,7 +108,8 @@ class StaccatoTransfer(xfer_base.TransferBase): headers=headers, body=json.dumps(data)) response = self.client.getresponse() if response.status != 200: - msg = _('Error requesting a new transfer %s. Status = %d') % (response.read(), response.status) + msg = (_('Error requesting a new transfer %s. Status = %d') % + (response.read(), response.status)) LOG.error(msg) raise exception.ImageDownloadModuleError( {'reason': msg, 'module': unicode(self)}) @@ -132,7 +133,8 @@ def get_download_hander(**kwargs): def get_schemes(): conf_group = CONF['staccato_nova_download_module'] try: - LOG.info("Staccato get_schemes(): %s:%s" % (conf_group.hostname, conf_group.port)) + LOG.info(("Staccato get_schemes(): %s:%s" % + (conf_group.hostname, conf_group.port))) client = httplib.HTTPConnection(conf_group.hostname, conf_group.port) client.request('GET', '/') response = client.getresponse() diff --git a/staccato/db/models.py b/staccato/db/models.py index 80f35a2..9c3d205 100644 --- a/staccato/db/models.py +++ b/staccato/db/models.py @@ -48,7 +48,6 @@ class XferRequest(BASE, ModelBase): executor_uuid = Column(String(512), nullable=True) - def register_models(engine): models = (XferRequest,) for model in models: diff --git a/tox.ini b/tox.ini index 36d1133..e4ef12b 100644 --- a/tox.ini +++ b/tox.ini @@ -9,8 +9,8 @@ setenv = VIRTUAL_ENV={envdir} NOSE_OPENSTACK_YELLOW=0.025 NOSE_OPENSTACK_SHOW_ELAPSED=1 NOSE_OPENSTACK_STDOUT=1 -deps = -r{toxinidir}/tools/pip-requires - -r{toxinidir}/tools/test-requires +deps = -r{toxinidir}/requirements.txt + -r{toxinidir}/test-requirements.txt commands = nosetests {posargs} [tox:jenkins]