the error message should include a line number.
what the exact error message, including the line number, and what is the code at that line of the page?
in your checkout process, did you elect to use one of the shipping rate providers?
when the checkout failure page loads, does the url contain a querystring parameter shipping=failed?
if so, the failure is a result of the shipping lookup.
go to the bindings panel, there will be a section for the shipping rate provider you selected, add the Full request and Full Response bindings to your page to see the response from the shipping provider.