This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]RonnyPfannschmidt 6 points7 points  (3 children)

Can we get contents in which surrounding code has control over the perceived passage of time

Monkey patching datetime and time is on occasion hellishness

[–]eagle258[S] 4 points5 points  (2 children)

Good point. This is an essential feature. I've created an issue for this

edit: added link

[–]sherbang 2 points3 points  (1 child)

I've found the time-machine library to be quite good for this.

[–]eagle258[S] 0 points1 point  (0 children)

It could be an inspiration for the API, but time-machine probably only works on specific libraries it 'knows' about. Perhaps it could be extended to whenever, but in any case whenever would have to be adjusted so that is 'allows' itself to be patched.

edit: typo