debugging key value error