The two men, Massata Samb and Amadou Niang from the opposition PUR party, were also ordered to pay a total of 5 million CFA francs ($8,200 or €7,600) in compensation to Amy Ndiaye, who is a member of the ruling Benno Bokk Yakaar coalition.
Ndiaye was hospitalized after the incident and risked losing the baby, her lawyer Baboucar Cisse said during the trial. She is now out of the hospital but remains in an "extremely painful" situation, he added.
What happened during the assault?
The brawl broke out on December 1 during a budget debate in the National Assembly during which Samb had criticized Ndiaye.
In televised footage that shocked Senegal, Samb could be seen slapping Ndiaye after she scoffed at his remarks.
Ndiaye responded by throwing a chair at Samb.
Other lawmakers then pushed Ndiaye to the ground, after which she was kicked in the abdomen by Niang.
Despite footage of the attack being broadcast around the country, the two men denied the charges of assault and battery. One of their lawyers said they would appeal the ruling.
"They are going to remain in prison pending an appeal," one of their lawyers, Abdy Nar Ndiaye, told the French AFP news agency.