freezegun
freezegun copied to clipboard
Setting tz_offset causes test fixture to freeze on yield in v1.1.0
Have an issue with 1.1.0, works fine with 1.0.0.
@pytest.fixture
def fixed_timestamp(timestamp, tz_offset) -> datetime.datetime:
freezer = freezegun.freeze_time(timestamp, tz_offset=tz_offset)
freezer.start()
yield datetime.datetime.now()
freezer.stop()
This code hangs at
yield datetime.datetime.now()
If I remove tz_offset it works.
any help from any dev would be appreciated
I also ran into this issue. In my case, the issue did not happen with 1.0.0 and it get a freezing test (with high CPU usage) with 1.1.0 (it might also be related to the usage of multiprocessing; I'll check again when this one is fixed.)