I just ran into a similar issue.
Instead of having something like this on your DTO:
#[Assert\Range(min: 0)]
#[Assert\NotNull()]
public float $price = null;
You can explicitly allow integers as well:
#[Assert\Range(min: 0)]
#[Assert\NotNull()]
public float|int|null $price = null;