Update hacking for Python3

The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.

Fix problems found.

Change-Id: Ica99c9a4affd2b693ef74f1e3ef7c8ea2c6a46d6
This commit is contained in:
Andreas Jaeger 2020-03-28 12:06:10 +01:00 committed by Andreas Jaeger
parent 4259f74ff1
commit a0c6625d20
3 changed files with 4 additions and 2 deletions

View File

@ -124,7 +124,7 @@ class MonascaPublisher(publisher.ConfigPublisherBase):
except Exception:
LOG.info(traceback.format_exc())
if hasattr(self, 'archive_handler'):
self.archive_handler.publish_samples(None, metrics)
self.archive_handler.publish_samples(None, metrics)
def publish_samples(self, samples):
"""Main method called to publish samples."""

View File

@ -1,3 +1,4 @@
hacking>=3.0,<3.1.0 # Apache-2.0
git+https://github.com/openstack/ceilometer.git@master#egg=ceilometer
mock>=1.2 # BSD
testscenarios>=0.4 # Apache-2.0/BSD
@ -11,4 +12,4 @@ oslo.log>=1.14.0 # Apache-2.0
os-testr>=1.0.0 # Apache-2.0
python-monascaclient<=1.12.0 # Apache-2.0
docutils>=0.11 # OSI-Approved Open Source, Public Domain
hacking<0.11,>=0.10.0

View File

@ -26,6 +26,7 @@ commands = {posargs}
max-line-length = 100
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build
show-source = True
ignore = E402,W504
[hacking]
import_exceptions =