Russian President Vladimir Putin will not attend the BRICS economic summit in Johannesburg next month, the office of South African President Cyril Ramaphosa said in a statement Wednesday.

The decision means South Africa will not face the dilemma of whether it should carry out an International Criminal Court arrest warrant against the Russian leader.

South Africa is a signatory to the treaty that created the ICC and would have been obliged under that to arrest Putin, although the country had given strong hints that it would have likely not executed the arrest warrant.

WAGNER MOVE TO BELARUS GIVE MERCENARY GROUP ABILITY TO QUICKLY STRIKE NATO, RUSSIAN POLITICIAN WARNS

But Wednesday's announcement allows South Africa to avoid the problem and comes after Ramaphosa spoke with Putin by telephone in recent days.

Russian President Vladimir Putin

Russian President Vladimir Putin is pictured during a meeting at the Kremlin in Moscow, Russia, on July 18, 2023.   (Alexander Kazakov, Sputnik, Kremlin Pool Photo via AP)

PUTIN REVEALS NEW DETAILS OF HIS OFFER TO WAGNER MERCENARIES

The decision for Putin not to attend was by "mutual agreement," Ramaphosa's office said. Russia will instead be represented at the Aug 22-24 summit by Foreign Minister Sergey Lavrov.

The BRICS economic bloc is made up of Brazil, Russia, India, China and South Africa. South Africa had invited the leaders of the other four countries to the summit before Putin's arrest warrant was issued by the ICC in March.

CLICK HERE TO GET THE FOX NEWS APP

The announcement brings to an end months of speculation over if Putin was going to travel to South Africa. Putin has not traveled to any country that is a signatory to the ICC treaty since he was indicted for war crimes over the abduction of children from Ukraine.