One important thing to recognize is that each get function will return a zero value if it’s not found.
However, on python 3.7.4:
v = vyper.Vyper()
v.get_string('bla')
'None'
v.get_int('bla')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/user/.local/lib/python3.7/site-packages/vyper/vyper.py", line 211, in get_int
return int(self.get(key))
TypeError: int() argument must be a string, a bytes-like object or a number, not 'NoneType'
v.get_float('bla')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/user/.local/lib/python3.7/site-packages/vyper/vyper.py", line 214, in get_float
return float(self.get(key))
TypeError: float() argument must be a string or a number, not 'NoneType'
Expected behavior is:
v = vyper.Vyper()
v.get_string('bla')
''
v.get_int('bla')
0
v.get_float('bla')
0.0
Docs says:
However, on python 3.7.4:
Expected behavior is: