KeyError is raised when value is `undefined` on a raw javascript object, and in javascript mode when inside a try/except KeyError block.