Fail properly on layername not found