DETROIT (AP) — Prosecutors accusing Detroit Mayor Kwame Kilpatrick of lying on the witness stand to cover up an extramarital affair with a top aide said Wednesday that a plea deal is expected soon, a surprise development that appeared likely to cost him his job.

The office of Wayne County prosecutor Kym Worthy said Wednesday that an agreement is expected soon, first saying it would come that afternoon and later saying it would be this morning.

The Detroit city charter automatically expels any mayor guilty of a felony. Kilpatrick is charged with eight felonies in the perjury case and would have to get them all reduced to misdemeanors — or beat the charges in court — in order to keep his job.