Payment Processor Error message: 10525: Invalid Data This transaction cannot be processed. The amount to be charged is zero

When using CiviCRM 4.6.4, we notice when adding a $0 (Free) item to a price set, and a user contributes, they are asked to confirm, but then get this error with our Paypal Website Payment Pro processor: Payment Processor Error message: 10525: Invalid Data This transaction cannot be processed. The amount to be charged is zero.  When someone chooses a$0 amount, no Paypal payment method is presented on the form, yet it still seems to opt-in to using that processor. We have no other payment processors enabled.

How do we fix?

We also notice that when using CiviDiscount,if we make a 100% off CODE for a membership, it is also rejected by Paypal with the above error.

• Just as a general note - it's worth testing things like this on the latest point version (4.6.5) as this is the sort of thing that is likely to have a fix in a point version. If you still experience it on 4.6.5 then log in JIRA & hopefully we can fix for next week's release – eileen Jul 30 '15 at 22:07
• But beware that 4.6.5 has some significant bugs around search and smart groups, e.g. Broken smart groups due to CRM-16858, Search for event participants from event page causes error DB Error: syntax error so you might not want to upgrade your production environment until 4.6.6 comes out if these will affect you. – davejenx Jul 31 '15 at 8:43
• I am having the identical problem – it emerged on 4.6.3 for us, and is still present having updated to 4.6.6. We cannot process Free memberships currently, and our community members are putting in \$0.01 donations as a workaround. – Daniel Ando Scholnick Aug 18 '15 at 17:08
• After lots of hunting, I found this stack exchange question that appears to have the answer to this question. If I can apply the patch and it works, I'll submit it as an answer here to this question. – Daniel Ando Scholnick Aug 19 '15 at 14:04