core: Show error message if _key dynamically passed into error [GH-2328]