You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## `FrozenDateTimeFactory.tick`
The `delta` argument is capable of handling `float`s. In previous versions of
freezgun, the `.pyi` type annotations were correctly reflecting that. For some
reason, when moving the type annotations into the `.py` file, this information
got lost.
Further, checking for `isinstance(delta, numbers.Real)` is probably not what
was intended as `fraction.Fraction` is a subclass of `Real`, but will cause an
error when passed into `datetime.timedelta(seconds=delta)`.
## `StepTickTimeFactory.tick`
The same issue with the type hint applies here.
Fruther, passing an integer/float `delta` would lead to that number being added
to the frozen `datetime.datetime`, which is not a valid operation
(`TypeError: unsupported operand type(s) for +: 'datetime.datetime' and 'int'`).
0 commit comments