Sometimes we hear of cases where a customer's financial institution (like their bank or credit card provider) blocks their transaction from completing, after it appears to have taken the money from the customer's account. That may explain the error you are seeing.
You financial institution may be blocking the transaction from completing, in order to protect you from fraud. If this is the case, you should see the charge reimbursed on your credit card within a few business days, or possibly much sooner. If the charge is not reversed, you should contact your credit card company.
Also, you should contact your financial institution to let them know this was really you, trying to make a legitimate purchase. Then, they may unblock you from making purchases from Leanpub.
Here is some business information you can give your financial institution about us: http://help.leanpub.com/reader-help/business-information-about-leanpub.