As you say, it shouldn't matter in your application, but without the actual qualification you will need very good references from your course tutors stating that you are highly likely to complete the MSc successfully. Even with valid personal reasons for poor performance your potential supervisor needs to know that, had you not had problems to deal with, you would have passed first time. If you believe your references will be good then you might as well begin applying. If your course tutors won't say whether they expect you to pass or fail then you might want to wait until you've got the MSc in the bag.