Weary MPs on both sides of the House of Commons have completed a marathon voting session on the Harper government's budget bill.

The voting, which began at 1 a.m. Thursday morning, ran non-stop until just after 11 p.m., more than 22 hours later.

MPs rose again and again in the House of Commons, working slowly and methodically through an exhaustive list of amendments to Bill C-38. The MPs who were in the House of Commons when the voting wrapped up were visibly relieved when the end finally came, cheering as the last vote of the night was cast.

MPs voted on 871 amendments that had been bundled into about 159 groups to speed the process.

Third reading for the bill is scheduled for Monday, then it goes to Senate.

Throughout Thursday morning, the Commons voted down amendments that would have removed the parts of the bill changing environmental regulations, one of the most contentious aspects of the omnibus legislation. The NDP caucus – particularly its back rows – appeared to be making a point of rising slowly to vote, one by exhausted one.

Opposition House Leader Nathan Cullen told reporters their slow pace was deliberate for the environmental clauses in particular, criticizing Conservative backbenchers for not having the courage of their convictions to break ranks.

"You steel your resolve a bit to know that people appreciate when the country is being bullied, when our Parliament is being bullied, there's someone who's going to push back, and that's essentially what's been happening the last several hours," Cullen said.

"If we had simply allowed the government to pass this bill without any inconvenience at all, the lesson they would have taken away, and Canadians would have taken away, is that Parliament is less important than it really is," the NDP house leader added.

But Finance Minister Jim Flaherty said the government is determined to pass the budget implementation bill.

"I think most Canadians, quite frankly, want us to move ahead with our economic agenda ... and that this is not a time for gamesmanship," Flaherty told reporters in the Commons foyer early Thursday afternoon.

The Conservative caucus was open about its strategy of dividing into small teams according to seat placement, with "columns" of MPs exiting the chamber to eat, shower, nap or take short walks while a critical mass of government MPs remained to ensure that each amendment failed.

Discipline in the ranks

Cullen suggested Government Whip Gordon O'Connor, a retired general, was keeping his troops on a short leash. 

When there was a "shift change" of break-taking MPs, confusion occasionally ensued over who was present to vote. MPs have to be in their seats when the "question is put" (the amendment is read from the Speaker's chair), and latecomers' votes are not supposed to be counted.

Liberal MP Marc Garneau told reporters Thursday morning that even though the opposition had lost all the votes up to that point, it was accomplishing its goal — even if the voting occurred while Canadians slept.  

"I'm getting the sense that Canadians realize that the government has abused its power. It did not need to do this. It is making profound changes in many areas to this country, and, yes, it has a majority, but it didn't need to bundle them all into one law and just sort of ram it through," Garneau said in the foyer of the House of Commons.

bruinoogefamily

Manitoba Conservative MP Rod Bruinooge had a visit from his family Thursday morning in the lobby adjacent to the Commons, where breakfast was served. This photo he circulated on Twitter shows them posing with Prime Minister Stephen Harper, who was also on a break. (Twitter)

Asked whether the overnight session was like being trapped in a space capsule, the former astronaut replied it was actually an "open and breezy" social environment inside the House chamber.

Cullen also revealed some lighter moments, including Foreign Affairs Minister John Baird's gift of a sash and tiara to NDP Deputy Leader Libby Davies, "which was nice," he said.

"But then you step away from those moments and you realize what you just voted on and what the government just rammed through," Cullen said. "Those moments sober you up real quick."

A brief controversy erupted when Prime Minister Stephen Harper re-entered the Commons after a break just before 8:30 a.m. ET and Green Party Leader Elizabeth May suggested he didn't arrive in time to have his vote counted. Harper insisted he had, supported by an intervention from Government Whip O'Connor, who is seated immediately behind Harper. The Speaker took him at his word, in accordance with Commons rules.

Coffee, closed eyes and candy

Observers overnight noticed MPs napping, or at least "resting their eyes" in their seats as others rose to vote. MPs are allowed only water in the Commons, but some MPs rose to complain about a colleague who brought in coffee, which is against the rules.

Interim Liberal leader Bob Rae and Quebec Liberal MP Justin Trudeau confessed on Twitter that they'd snuck in candy.

Early Thursday afternoon reports from MPs on Twitter suggest that seven NDP MPs had not missed a single vote. Three Liberal MPs are also said not to have slept.

In another brief burst of excitement, one amendment was defeated on a voice vote mid-Thursday morning, sparing MPs that particular round of rising in their places. Opposition MPs farther back in the chamber claimed not to have heard when it was their turn to yell in favour of a recorded standing vote, in a ritual repeated before every vote.

In a voice vote, MPs remain seated and yell yea or nay when prompted by the Speaker.

If the opposition had won a vote, it may have only created a minor inconvenience for the government, which could circle back and reinstate the original clause or clauses in future legislation.

The final Commons vote on the budget bill as a whole is expected after its final stage of debate, early next week.

Cullen described its future passage through the Conservative-dominated Senate as similar to a "hot knife through butter."

Toll on Commons staff

The extended voting took its toll on Commons staff, who had to be present through to the end, working overtime through rotating shifts.

One clerk was heard briefly on an inadvertently live microphone early Thursday morning saying she was going home because she needed to sleep.

While the marathon voting tested current MPs, it is not unprecedented. In 1999, the House of Commons endured a record 43 hours of voting on 471 Reform Party amendments to the then-Liberal government's legislation to implement the Nisga'a treaty.

Mobile users, follow the live blog here.

With files from The Canadian Press