The Ramban writes (Shemos 4, 21) that Moshe was the only person who could perform the numerous miracles in front of Paroh, and redeem Bnei Yisrael. With this in mind, says Rav Wolbe (Shiurei Chumash) it is difficult to understand the scenario described at the end of the parsha. Moshe, his wife Tziporah, and their children are on the way back to Mitzrayim. They stop off at an inn and an angel comes to kill Moshe for being derelict regarding the circumcision of his son.
Let's take a moment to properly appreciate what was about to happen. If Moshe Rabbeinu would have been killed there would be no redeemer for Bnei Yisrael! There was no second string redeemer; it was either Moshe or no one! How can we possibly understand that after Hashem spent a week "convincing" Moshe to agree to become the redeemer, He then sent an angel to kill him? The truth is that we have no answer. When it comes to middas ha'din (strict letter of the law judgment) we simply cannot comprehend Hashem's ways at all.
On Shabbos, we say in birchos Krias Shema, "Who gives light to the entire world which He created with compassion." The rachamim mentioned, refers to that which Hashem gave us the ability to understand the workings of the world. There is a meticulous order to all aspects of nature, and, to a certain extent, we can know what to expect. In contrast, middas ha'din seems to confront people without rhyme or reason. While no one questions middas ha'rachamim, when, chas v'shalom, a person is challenged with midas ha'din, he starts asking, "Why?" In most instances we do not have an answer to his question.
Additionally, interestingly enough, while Hashem deals with most people with middas ha'rachamim, he acts with those closest to Him with strict judgment. We are used to the exact opposite type of behavior. When a close aide, or someone greatly needed in the hierarchy, slips up, his mistake is usually overlooked. Because he is such a great asset to the government or company, he is forgiven and the blunder is swept under the carpet. In Yiddishkeit, Chazal tell us that the opposite is true. "Hashem is meticulous with the pious and punishes them for an infraction even the size of a hairsbreadth."
There was no one closer to Hashem than Moshe, and there was no one more needed at that time than Moshe who was to act as the redeemer. Nevertheless, when he erred ever so slightly, the punishment was immediate in coming. The rationale is, the closer a person is to perfection, the greater the demand that he reach that pinnacle. If all he is missing is a hairsbreadth to reach the finish line, Hashem will not overlook that minor infraction, despite the fact that such an infraction is seemingly overlooked when performed by other people.
We cannot comprehend Hashem's ways. Truth be told, says Rav Wolbe, this applies not only to middas ha'din, but also with regard to middas ha'rachamim. While we think we know the workings of nature, we don't really know what is going on. Every single day new marvels of creation are discovered, leaving us confounded and in awe of the Creator. Yet, this very knowledge that we cannot fathom Hashem's deeds, coupled with an ironclad faith that everything He does is solely for our good, should grant one a sense of security in any situation with which he may be confronted!