fix python version compat
This commit is contained in:
parent
8958481637
commit
d8f94e5aa2
|
@ -1,4 +1,7 @@
|
||||||
def try_float(value: str) -> int | float | str:
|
from typing import Union
|
||||||
|
|
||||||
|
|
||||||
|
def try_float(value: str) -> Union[int, float, str]:
|
||||||
try:
|
try:
|
||||||
return float(value)
|
return float(value)
|
||||||
except:
|
except:
|
||||||
|
|
Loading…
Reference in New Issue