Thanks for the reply James. Just to be clear, I only changed the file after the initial import failed.
If you google the error message you find that it is a very common problem, and has been for several years, and I am struggling to find any official response from the Wordpress team. All the "changes" I reported in my OP were fixes that other people had reported - None of which worked for me.
I will contact the wordpress support team.