I just realised today in 5.1.59, YAML product import is allowing creation of duplicate products (I.e. Those with same name as existing). This doesn’t throw error during import but if you open a duplicate product you can’t save it (it shows error about duplicate product).
Normal batch product import doesn’t do this - product is just ignored.
On a side note, could we have it if duplicates are found during import that it shows a summary after import saying that X duplicates were found and list those duplicates? Would be quite useful as I always have to double check for duplicates manually.