diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9d945567450344fa94ec9e6280095e86a6c532b0..08aef91b213be4ddd939a50b8dc41a603a8cc14f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -9,7 +9,7 @@ default_language_version: repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: ebc15addedad713c86ef18ae9632c88e187dd0af # v3.1.0 + rev: 9136088a246768144165fcc3ecc3d31bb686920a # v3.3.0 hooks: - id: trailing-whitespace # Replaces or checks mixed line ending @@ -27,9 +27,13 @@ repos: - id: debug-statements - id: check-yaml files: .*\.(yaml|yml)$ - - repo: https://gitlab.com/pycqa/flake8 - rev: 181bb46098dddf7e2d45319ea654b4b4d58c2840 # 3.8.3 + - repo: local hooks: - id: flake8 + name: flake8 additional_dependencies: - hacking>=3.0.1,<3.1.0 + language: python + entry: flake8 + files: '^.*\.py$' + exclude: '^(doc|releasenotes|tools)/.*$' diff --git a/.zuul.yaml b/.zuul.yaml index 842503010e8067207e14a591251da141657d69b2..84bb45c2f858c4e54d39cadce50ede7e7390c34e 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -2,7 +2,7 @@ templates: - check-requirements - lib-forward-testing-python3 - - openstack-python3-wallaby-jobs + - openstack-python3-xena-jobs - periodic-stable-jobs - publish-openstack-docs-pti - release-notes-jobs-python3 diff --git a/doc/source/conf.py b/doc/source/conf.py index 3e96e805125c287a18fb3b727dbfa48d0df7d437..f0ff4d1c07e944b0310b837e12204da52f170ea5 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -45,8 +45,8 @@ source_suffix = '.rst' master_doc = 'index' # General information about the project. -project = u'oslo.service' -copyright = u'2014, OpenStack Foundation' +project = 'oslo.service' +copyright = '2014, OpenStack Foundation' # If true, '()' will be appended to :func: etc. cross-reference text. add_function_parentheses = True @@ -76,6 +76,6 @@ htmlhelp_basename = '%sdoc' % project latex_documents = [ ('index', '%s.tex' % project, - u'%s Documentation' % project, - u'OpenStack Foundation', 'manual'), + '%s Documentation' % project, + 'OpenStack Foundation', 'manual'), ] diff --git a/lower-constraints.txt b/lower-constraints.txt deleted file mode 100644 index 029b96a38dfa324d58af4810bd331448231a2056..0000000000000000000000000000000000000000 --- a/lower-constraints.txt +++ /dev/null @@ -1,63 +0,0 @@ -alabaster==0.7.10 -appdirs==1.3.0 -Babel==2.3.4 -bandit==1.1.0 -chardet==3.0.4 -coverage==4.0 -debtcollector==1.2.0 -doc8==0.6.0 -docutils==0.11 -dulwich==0.15.0 -eventlet==0.25.2 -extras==1.0.0 -fasteners==0.7.0 -fixtures==3.0.0 -gitdb==0.6.4 -GitPython==1.0.1 -greenlet==0.4.15 -imagesize==0.7.1 -iso8601==0.1.11 -Jinja2==2.10 -keystoneauth1==3.4.0 -linecache2==1.0.0 -MarkupSafe==1.0 -mox3==0.20.0 -msgpack-python==0.4.0 -netaddr==0.7.18 -netifaces==0.10.4 -os-client-config==1.28.0 -oslo.concurrency==3.25.0 -oslo.config==5.1.0 -oslo.context==2.19.2 -oslo.i18n==3.15.3 -oslo.log==3.36.0 -oslo.serialization==2.18.0 -oslo.utils==3.40.2 -oslotest==3.2.0 -Paste==2.0.2 -PasteDeploy==1.5.0 -pbr==2.0.0 -Pygments==2.2.0 -pyinotify==0.9.6 -pyparsing==2.1.0 -python-dateutil==2.5.3 -python-mimeparse==1.6.0 -python-subunit==1.0.0 -pytz==2013.6 -PyYAML==3.13 -repoze.lru==0.7 -requests==2.14.2 -requestsexceptions==1.2.0 -restructuredtext-lint==1.1.1 -rfc3986==0.3.1 -Routes==2.3.1 -smmap==0.9.0 -snowballstemmer==1.2.1 -stestr==2.0.0 -stevedore==1.20.0 -testtools==2.2.0 -traceback2==1.4.0 -unittest2==1.1.0 -WebOb==1.7.1 -wrapt==1.7.0 -Yappi==1.0 diff --git a/oslo_service/service.py b/oslo_service/service.py index c9d6bd0ba9f6c774302fb4674164c8471d0aabd0..fa9c37c23caf8c4ae66321828aeb1516f715ef91 100644 --- a/oslo_service/service.py +++ b/oslo_service/service.py @@ -197,12 +197,11 @@ class SignalHandler(metaclass=Singleton): def __setup_signal_interruption(self): """Set up to do the Right Thing with signals during poll() and sleep(). - For Python 3.5 and later, deal with the changes in PEP 475 that prevent - a signal from interrupting eventlet's call to poll() or sleep(). + Deal with the changes introduced in PEP 475 that prevent a signal from + interrupting eventlet's call to poll() or sleep(). """ select_module = eventlet.patcher.original('select') - self.__force_interrupt_on_signal = (sys.version_info >= (3, 5) and - hasattr(select_module, 'poll')) + self.__force_interrupt_on_signal = hasattr(select_module, 'poll') if self.__force_interrupt_on_signal: try: diff --git a/oslo_service/tests/test_service.py b/oslo_service/tests/test_service.py index 58be122b82e041e6fc7e046498f26f4adf0be6e5..fad33e93d3ac9dd8a7658fcd29ac69f6258bc636 100644 --- a/oslo_service/tests/test_service.py +++ b/oslo_service/tests/test_service.py @@ -476,7 +476,6 @@ class ProcessLauncherTest(base.ServiceBaseTestCase): m.assert_called_once_with(signal.SIGTERM, 'test') signal_handler.clear() - @mock.patch('sys.version_info', (3, 5)) def test_setup_signal_interruption_no_select_poll(self): # NOTE(claudiub): SignalHandler is a singleton, which means that it # might already be initialized. We need to clear to clear the cache @@ -490,7 +489,6 @@ class ProcessLauncherTest(base.ServiceBaseTestCase): self.assertFalse( signal_handler._SignalHandler__force_interrupt_on_signal) - @mock.patch('sys.version_info', (3, 5)) def test_setup_signal_interruption_select_poll(self): # NOTE(claudiub): SignalHandler is a singleton, which means that it # might already be initialized. We need to clear to clear the cache diff --git a/releasenotes/source/conf.py b/releasenotes/source/conf.py index dd1993fb86b5b3b5725a6a755e5cc46c4fbcf536..da135d3e75b8dcb2edc42ce0b11991b5dbe65321 100644 --- a/releasenotes/source/conf.py +++ b/releasenotes/source/conf.py @@ -60,8 +60,8 @@ source_suffix = '.rst' master_doc = 'index' # General information about the project. -project = u'oslo.service Release Notes' -copyright = u'2016, oslo.service Developers' +project = 'oslo.service Release Notes' +copyright = '2016, oslo.service Developers' # Release notes do not need a version in the title, they span # multiple versions. @@ -208,8 +208,8 @@ latex_elements = { # author, documentclass [howto, manual, or own class]). latex_documents = [ ('index', 'oslo.serviceReleaseNotes.tex', - u'oslo.service Release Notes Documentation', - u'oslo.service Developers', 'manual'), + 'oslo.service Release Notes Documentation', + 'oslo.service Developers', 'manual'), ] # The name of an image file (relative to this directory) to place at the top of @@ -239,8 +239,8 @@ latex_documents = [ # (source start file, name, description, authors, manual section). man_pages = [ ('index', 'oslo.serviceReleaseNotes', - u'oslo.service Release Notes Documentation', - [u'oslo.service Developers'], 1) + 'oslo.service Release Notes Documentation', + ['oslo.service Developers'], 1) ] # If true, show URL addresses after external links. @@ -254,8 +254,8 @@ man_pages = [ # dir menu entry, description, category) texinfo_documents = [ ('index', 'oslo.serviceReleaseNotes', - u'oslo.service Release Notes Documentation', - u'oslo.service Developers', 'oslo.serviceReleaseNotes', + 'oslo.service Release Notes Documentation', + 'oslo.service Developers', 'oslo.serviceReleaseNotes', 'Provides a framework for defining new long-running services using the' ' patterns established by other OpenStack applications', 'Miscellaneous'), diff --git a/releasenotes/source/index.rst b/releasenotes/source/index.rst index 05123c9a74d1822fe2b51758e1956bc92f28203f..0d4a4e69077ffaa50d74c0cf4c79c4901a3b10b1 100644 --- a/releasenotes/source/index.rst +++ b/releasenotes/source/index.rst @@ -6,6 +6,7 @@ :maxdepth: 1 unreleased + wallaby victoria ussuri train diff --git a/releasenotes/source/wallaby.rst b/releasenotes/source/wallaby.rst new file mode 100644 index 0000000000000000000000000000000000000000..d77b56599553b6fe996624b33c1663168342fb94 --- /dev/null +++ b/releasenotes/source/wallaby.rst @@ -0,0 +1,6 @@ +============================ +Wallaby Series Release Notes +============================ + +.. release-notes:: + :branch: stable/wallaby diff --git a/setup.cfg b/setup.cfg index bd3f33574cc1a9770cdd42749e9df3c116e4450e..902899ed74265009c3e7ecfe7ff530006fca8d2b 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,12 +1,12 @@ [metadata] name = oslo.service summary = oslo.service library -description-file = +description_file = README.rst author = OpenStack -author-email = openstack-discuss@lists.openstack.org -home-page = https://docs.openstack.org/oslo.service/latest/ -python-requires = >=3.6 +author_email = openstack-discuss@lists.openstack.org +home_page = https://docs.openstack.org/oslo.service/latest/ +python_requires = >=3.6 classifier = Environment :: OpenStack Intended Audience :: Information Technology diff --git a/tox.ini b/tox.ini index 2e1e2e34d4fe34f2f74910591cbdf016037425e3..50f850aac425d6bc1f4e4e359f7e74bd91119af5 100644 --- a/tox.ini +++ b/tox.ini @@ -66,8 +66,3 @@ commands = rm -rf releasenotes/build sphinx-build -a -E -W -d releasenotes/build/doctrees --keep-going -b html releasenotes/source releasenotes/build/html -[testenv:lower-constraints] -deps = - -c{toxinidir}/lower-constraints.txt - -r{toxinidir}/test-requirements.txt - -r{toxinidir}/requirements.txt