Version 4.2.1 treats warnings as exceptions
Description
Current version (4.2.1, maybe the previous one too) converts all warnings into exceptions. Output of warnings filter shows:
('error', None, <class 'Warning'>, None, 0)
In my case, in particular, it blocks sending HTTPS requests with parameter verify=False.
Possible reason
File config/master.py contains variable _in_unit_tests, which set to False by default but it become True after calling monkeypatches, so function get_is_in_unit_tests() starts to return True.
File db/logs.py contains code:
...
if get_is_in_unit_tests():
from buildbot.test.fake.reactor import NonThreadPool
...
Importing test.fake.reactor here leads to call warnings.filterwarnings('error') from test/__init__.py
I can confirm this. I'm currently working this around by:
import buildbot.config.master
buildbot.config.master.get_is_in_unit_tests = lambda: False
import buildbot.db.logs
buildbot.db.logs.get_is_in_unit_tests = lambda: False
in buildmaster config.
Related: #8278
Is this fixed in 4.3.0 for you?