Due to the unordered nature of sets, it is possible for signal
handlers like _gracefull_shutdown() to run first and clear the
_signal_handlers before other registered handlers have run.
This patch converts _signal_handlers from a set to a list and
then runs the handlers LIFO similar to how atexit functions are
run. Given that the handlers added in service.py are added after
clearing the signal_handlers, they are guaranteed to be the first
in the list and the last run.
Change-Id: Ief3ab2f56fa3d805296709e12e5f7a71560f7b6e
Closes-Bug: #2057809
Related-Bug: #2056366
Signed-off-by: Terry Wilson <twilson@redhat.com>
Add file to the reno documentation build to show release notes for
stable/2024.1.
Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/2024.1.
Sem-Ver: feature
Change-Id: Ide682d061e1c18cc994eca93624ab5d9126edb26
We also remove these unnecessary linter dependencies from
test-requirements.txt.
The independent bandit target was removed because it's integrated to
the pep8 target.
Co-Authored-By: Stephen Finucane <sfinucan@redhat.com>
Change-Id: I094897e6de223753a5a497ec42348e4449132b17
hacking 3.0.x is too old.
Also, fixtures appears in both requirements and test-requirements.
Because this library is only used in oslo_service.fixtures for testing,
we can remove it from runtime requirements.
Change-Id: Iaf57598a73af62e07e890245dc51c9af6a807bd7
As per the current release tested runtime, we test
python version from 3.8 to 3.11 so updating the
same in python classifier in setup.cfg
Change-Id: I709f3609f52b7d75a0c176d5ecb0704600a00c8b
Add file to the reno documentation build to show release notes for
stable/2023.2.
Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/2023.2.
Sem-Ver: feature
Change-Id: I5f7a274cd826dd083f2b7e93b6741620bdaa5883
Within 2023.2 python version 3.9 and 3.10 are the
supported python runtimes [1].
[1] https: //review.opendev.org/c/openstack/governance/+/872232
Change-Id: If044570184e1df33c8754a39a782ea94e4ea165f
Add file to the reno documentation build to show release notes for
stable/2023.1.
Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/2023.1.
Sem-Ver: feature
Change-Id: I84cb4b959ab10d4930856d7a6c3077444a136c2b
Add file to the reno documentation build to show release notes for
stable/zed.
Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/zed.
Sem-Ver: feature
Change-Id: I9dc519f12735bb2d98824ba6c5d775bc323afff0
When the parent process used eventlet tpool to run code in native
threads then anything the child tries to run in a native thread will
hang forever.
The reason for that is that the parent has initialize the pool of
threads and use a flag to mark that it has been initialized, and when
the child is forked then it will have the flag saying that it has been
initialized and expects the threads to be running, but they are not. So
there is no thread to pick up the job when a greenlet queues the job, so
the greenthread waits forever to get the result of the operation.
This patch tells eventlet's tpool to clean things up on the child just
after forking, that way if the child uses native threads tpool will
spawn all the threads again.
Closes-Bug: #1983949
Change-Id: If2421427c48faa976d6c6ee9bafe4d563288037b
In Zed cycle testing runtime, we are targetting to drop the
python 3.6/3.7 support, project started adding python 3.8 as minimum,
example nova:
- 56b5aed08c/setup.cfg (L13)
Also indicates that we support python 3.9.
Change-Id: Ic6dd48a11ae639ad9bc0ebeeffce7483c8bed588
Add file to the reno documentation build to show release notes for
stable/yoga.
Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/yoga.
Sem-Ver: feature
Change-Id: I6e5c1ce720b69cc2ba98b73fe6c8d193ca338ad6
The backdoor command fo() uses isinstance() to check if an object is an
instance of a class. This only works with objects that have a __class__
attribute, else an AttributeError is raised by isinstance(). This is
seldomly the case, though if there is one such object fo() will cease to
work. Therefore we need to protect us against this case by checking for
a __class__ attribute before calling isinstance().
An example for an object without __class__ would be
functools._lru_list_elem.
Change-Id: Ia4c5cbdc249535d36f6e71f7b2a7359bc6fdf219
Closes-Bug: #1946072
The backoff looping call logging was previously making
a decision on if timeout had or was going to be exceeded
by including idle time and it's internal time, however
this is misleading as the overall operation may take
30 seconds externally, a user initiated timeout of 30
seconds is requested, and the error might say something
like 18 seconds has passed, when that is incorrect.
The logic is actualy correct, the logging was just
misleading.
Fixes the exception message to use the total time.
Change-Id: Ie9ef5a53abb24f6ab7de0ad57a672c0a8d7ff0ee
Add file to the reno documentation build to show release notes for
stable/xena.
Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/xena.
Sem-Ver: feature
Change-Id: I218ac5f11e3ac8042988d91b6a2beef3522dde70
Setuptools v54.1.0 introduces a warning that the use of dash-separated
options in 'setup.cfg' will not be supported in a future version [1].
Get ahead of the issue by replacing the dashes with underscores. Without
this, we see 'UserWarning' messages like the following on new enough
versions of setuptools:
UserWarning: Usage of dash-separated 'description-file' will not be
supported in future versions. Please use the underscore name
'description_file' instead
[1] https://github.com/pypa/setuptools/commit/a2e9ae4cb
Change-Id: Ide75d5a0fb9215a81f0410b6ffa77849463cf888