Change key lookup to .items() in self setattr in action