Can you put an f before your f-string's brackets to see if it works then?
Ran this code over here with python3 and it worked:
number = float(input('blabla \n'))
number = float(f"{number:.2f}") # f"{fstring formatting here}"
print(number)
print(type(number))
Output:
blabla
0.556
0.56
<class 'float'>