giving spies a name for better error feedback + minor variable name change #604