I have simple JSON and after for I am reading values inside it.
this is a code:
for row in returned_data['devices']:
print (row['version'])
script print all "version" values and in the end
Traceback (most recent call last):
File "api.py", line 370, in <module>
main(sys.argv[1:])
File "api.py", line 71, in main
print (row['version'])
KeyError: 'version'
Why?
returned_data['devices']which doesn't have keyversion.