From MoodleDocs
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

The error message " firstname" is not a valid field name is shown when an upload users text file contains spaces between the fields. Fields should be separated by a comma (or other delimiter) ONLY - no space. Not to be confused with error/moodle/cannotmapfield