<human>:  get field by name nil on missing.
<bot>:
  except KeyError:
    return None

# Enter the dictionary
d = {"a": 1, "b": 2}

# Calling the function
print((get_field_by_name(d, "a")))

#Example Output
# 1

#Remember to inspect code for bugs.