fixed bug: key_to_code was incorrectly not parsing tuples and lists