When importing a file, Sc creates the TODO file (copy of your file) and processes it line by line, one after the other and deleting them as they are processed correctly.
When an error occurred, the import stops and the error is displayed in the bottom right panel.
The line of the TODO file is being processed => error occurs => the line is not processed
Therefore, the error comes from that first line of the TODO file that Sc cannot process (the previous ones processed correctly have neen deleted).
To find out which product is on that first line, you can select the TODO file in the top panel, and hit the 'quick edition' icon on the toolbar - the first 20 lines will be displayed.
This quick edition mode allows you to quickly edit the TODO file to check the information of that first line generating the error.
If the problem comes from the information in the file, then fix it in the quick edition mode interface, save and restart your import. The process will restart where it started, meaning the first line of the TODO file that you just fixed.
Taking the example of the error 'name is not valid' stopping the import, we select the TODO, open the quick edition window => check the product name on the first line => edit + fix => save => restart the import (TODO file).
Exception: sometimes the first line of the TODO file is not the line generating the error when it's a skipped line - check article below explaining skipped lines.