OTTAWA -- A federal agency has ordered Air Transat to cover out-of-pocket expenses for passengers who were caught in an hours-long tarmac delay this summer as part of a ruling that slams the airline's handling of the fiasco.

The Canadian Transportation Agency said Air Transat broke its tariff agreement with customers about when they can be let off a flight due to a tarmac delay.

The ruling made public Thursday comes almost four months after two flights -- one from Rome, the other from Brussels -- sat on the tarmac in Ottawa for almost five and six hours, respectively, with passengers not allowed to disembark.

One of the two aircraft ran out of fuel during the delay, then lost power, causing the air conditioning system to shut down.

During two days of hearings in August, passengers described how tensions mounted as temperatures rose, a child threw up on board one plane and ultimately a passenger on the Brussels flight called 911, attracting widespread media attention.

A number of people who were on board the planes told the hearings they would have given anything to be allowed to disembark, even if it meant additional delays or a two-hour drive back to Montreal.

Weather caused the two flights to be diverted to Ottawa on July 31, along with about 20 other planes in an incident that appears to have taxed airport resources in the national capital to their limit. Fuelling teams, for instance, ran out of fuel on several occasions.

Among the planes was an Airbus 380, the largest to land that day.

The need to find a place to park that Air Emirates flight forced crews to move the two Air Transat planes to the airport taxiway, where they could be neither refuelled nor serviced. As a result, they ended up being among the last planes to be refuelled.

The airline argued it shouldn't be held liable for what happened, blaming the airport authority and refuellers among others for the delays.

Transportation agency members agree that Air Transat was not solely responsible for the delays, but said the extraordinary situation didn't relieve Air Transat from its commitment to its customers.

The agency said Air Transat's tariff agreement with customers is too broad and gives pilots too much discretion about when to let passengers leave an airplane, despite wording that says passengers have the option of disembarking after a 90-minute delay.

Air Transat must amend the wording to require passengers to disembark after a delay of four hours, unless there are safety, security, or air traffic control issues that prevent it.

The airline is also being ordered to amend its rules to update passengers every 30 minutes. It also said the airline must ensure there are working bathrooms and provide medical assistance as needed during long delays.

A representative from Air Transat was not immediately available to respond to the ruling.

The federal government's proposed air passenger bill of rights, which is stuck in the Senate, would set strict new standards for airlines to follow when flights are cancelled or delayed.