NAIROBI, Kenya -- Despite a surge of doping cases over the past four years and an increasingly dysfunctional and now suspended drug-testing agency, Kenya's athletes were cleared to compete at the Rio de Janeiro Olympics by the IAAF on Friday.

The International Olympic Committee, which has the final call on whether Kenya's famed distance runners will run in Rio in August, is unlikely to stop the country from sending a team.

"That's good news, hey," Kenya track federation president Jackson Tuwei said, laughing in apparent relief. "That's real good news. That is the best news I've had, at least for today."

It had been a fretful 24 hours for Tuwei and others after the World Anti-Doping Agency's unexpected decision Thursday to suspend Kenya's national anti-doping body over flawed legislation passed by lawmakers last month. The declaration of noncompliance by WADA raised the possibility that the IAAF might be emboldened to seek a sterner punishment for Kenya, as it did last year when it banned Russia following a crisis at its anti-doping agency.

But the IAAF said a ruling it made on Kenya in March -- when the East African nation was put on a doping "monitoring list" until the end of the year -- would stand.

"During the monitoring process ... Kenyan athletes remain eligible to compete nationally and internationally," the IAAF said in a statement Friday.

The IOC would discuss Kenya at its executive board meeting in Lausanne, Switzerland, next month, it said. But it is highly unlikely to ban Kenya's entire Olympic team because of the failures of the national anti-doping agency. That would be unprecedented.

Kenya's track and field athletes will not be banned from the Rio Olympics this summer, the IAAF said Friday. Margaret Bowles/AP Photo

A country's anti-doping agency "can be non-compliant for a number of reasons, there are currently a number of others in this position. It does not mean that the athletes will be stopped from participating in the Olympic Games," the IOC said.

Kenyans -- athletes, track officials and top political figures -- feared the worst.

Javelin world champion Julius Yego said he wasn't sure whether he should continue training for Rio because the effort might be for naught. Wesley Korir, a member of the Kenyan Olympic marathon team and himself a lawmaker, blamed the government's sports ministry officials for messing up the legislation. The anti-doping body's head declined to speak to the media.

It went right to the top: Kenyan President Uhuru Kenyatta, who personally pushed the now-flawed legislation through parliament, summoned officials to ask why the law had been rejected by WADA. The Kenyan government also requested an urgent meeting with WADA in Canada to clarify what it needed to do to become compliant with global rules as soon as possible.

Although critical of Kenya's "level of commitment to anti-doping" on Friday, the IAAF won't punish the athletes like Yego and David Rudisha, the 800-meter world-record holder, reigning Olympic champion and star of the 2012 London Games.

"I must appreciate the consideration the IAAF has given to this situation so at least the athletes who have been preparing and training for the Olympics get a chance to go and compete just like everybody else," Tuwei said.

Kenya still has challenges, though, with the IAAF demanding that its anti-doping program be "significantly strengthened by the end of the current year."

If it isn't, Kenya's Olympic champions from Rio 2016 -- and there's likely to be a few -- could be on the sideline in 2017.