READING, Pa. -

A "risky financial agreement" has cost the Hamburg Area School District nearly $4.5 million in taxpayer money, according to Pennsylvania's auditor general.

The district was hit with $2.38 million in termination fees to end a financial management "swap" after losing a net $2.05 million on the investment over six years, according to the results of a recent audit announced by Auditor General Eugene DePasquale during a stop in Reading on Tuesday.

"Every possible dollar needs to get into the classroom. Four million dollars could have gone towards improving education in the Hamburg area without placing an additional burden on taxpayers," DePasquale said.

Swaps are complicated financial contracts between school districts and investment banks and rely on unpredictable and, often risky, factors, DePasquale said.

The district entered the swap in May 2005 and incurred the termination fees in March 2011 to end the agreement, which swapped a variable interest rate for a fixed interest rate on a $25 million general obligation bond, according to the auditor general.

Hamburg Area school officials, according to DePasquale, responded to the audit by saying they wanted predictable costs and better budgeting with a fixed interest rate on the bond issue, rather than a variable one.

"Sometimes these swap deals pay off. Most times they are unpredictable. In this case, taxpayers were left with hefty termination fees and a net loss over six years," DePasquale said.

The audit also found that Hamburg erroneously reported $17,356 in payouts of unused vacation and personal leave for three administrators as retirement wages to the Public School Employees' Retirement System, DePasquale said.

As for the swap, Hamburg is the latest example of such an agreement that cost taxpayers money. An audit by the auditor general's office in 2013 found that the Oley Valley School District lost $6.5 million in swap financing agreements.

WFMZ's Ryan Hughes will have more on this story in a live report on 69 News at 5:30.