O you who have believed, prescribed for you is legal retribution for those murdered – the free for the free, the slave for the slave, and the female for the female...(2:178)
The law of retribution is established here.
And never is it for a believer to kill a believer except by mistake. And whoever kills a believer by mistake – then the freeing of a believing slave and a compensation payment [diyah] presented to his [i.e., the deceased's] family [is required], unless they give [up their right as] charity. But if he [i.e., the deceased] was from a people at war with you and he was a believer – then [only] the freeing of a believing slave; and if he was from a people with whom you have a treaty – then a compensation payment presented to his family and the freeing of a believing slave. And whoever does not find [one or cannot afford to buy one] – then [instead], a fast for two months consecutively, [seeking] acceptance of repentance from Allah. And Allah is ever Knowing and Wise. ([4] An-Nisa : 92)
And here the murder of a believer is allowed only by mistake.
That is, in fact, it follows from the text that verse 4:92 cancels verse 2:178 in relation to Muslims. In other words, a Muslim can only be killed by mistake, and therefore it follows from the text that qisas or the execution of Muslims for any crime is prohibited.
But the interpretations of the Koran tell us the opposite: that verse 2:178 also applies to Muslims and that a Muslim should be executed for killing another Muslim. I know that this principle of retribution is correct, but I cannot understand why then 4:92 says that a Muslim can only be killed by mistake.
My question is: How to explain that verse 4:92 does not cancel verse 2:178 in relation to Muslims?