Enforce H405 check
Change-Id: I61170d3b8cebd6e3e381f33ddc52b6d0174efec4
This commit is contained in:
parent
f544d9b3f9
commit
eea13af645
@ -149,8 +149,9 @@ class _PeriodicTasksMeta(type):
|
||||
|
||||
|
||||
def _nearest_boundary(last_run, spacing):
|
||||
"""Find nearest boundary which is in the past, which is a multiple of the
|
||||
spacing with the last run as an offset.
|
||||
"""Find the nearest boundary in the past.
|
||||
|
||||
The boundary is a multiple of the spacing with the last run as an offset.
|
||||
|
||||
Eg if last run was 10 and spacing was 7, the new last run could be: 17, 24,
|
||||
31, 38...
|
||||
|
@ -197,8 +197,7 @@ class PeriodicTasksTestCase(base.ServiceBaseTestCase):
|
||||
|
||||
|
||||
class ManagerMetaTestCase(base.ServiceBaseTestCase):
|
||||
"""Tests for the meta class which manages the creation of periodic tasks.
|
||||
"""
|
||||
"""Tests for the meta class which manages creation of periodic tasks."""
|
||||
|
||||
def test_meta(self):
|
||||
class Manager(periodic_task.PeriodicTasks):
|
||||
|
@ -25,7 +25,8 @@ LOG = logging.getLogger(__name__)
|
||||
|
||||
|
||||
def _thread_done(gt, *args, **kwargs):
|
||||
"""Callback function to be passed to GreenThread.link() when we spawn()
|
||||
"""Callback function to be passed to GreenThread.link() when we spawn().
|
||||
|
||||
Calls the :class:`ThreadGroup` to notify if.
|
||||
|
||||
"""
|
||||
@ -33,9 +34,11 @@ def _thread_done(gt, *args, **kwargs):
|
||||
|
||||
|
||||
class Thread(object):
|
||||
"""Wrapper around a greenthread, that holds a reference to the
|
||||
:class:`ThreadGroup`. The Thread will notify the :class:`ThreadGroup` when
|
||||
it has done so it can be removed from the threads list.
|
||||
"""Wrapper around a greenthread.
|
||||
|
||||
Holds a reference to the :class:`ThreadGroup`. The Thread will notify
|
||||
the :class:`ThreadGroup` when it has done so it can be removed from
|
||||
the threads list.
|
||||
"""
|
||||
def __init__(self, thread, group):
|
||||
self.thread = thread
|
||||
|
2
tox.ini
2
tox.ini
@ -32,7 +32,7 @@ commands = python setup.py testr --coverage --testr-args='{posargs}'
|
||||
# E123, E125 skipped as they are invalid PEP-8.
|
||||
|
||||
show-source = True
|
||||
ignore = E123,E125,H405
|
||||
ignore = E123,E125
|
||||
builtins = _
|
||||
exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user