Contributions fail with "Authorization failed" (in master only)
You can see this at https://dmaster.demo.civicrm.org/civicrm/contribute/transact?id=1&reset=1 just complete the transaction to the end (as an anonymous user) and you get
Payment Processor Error message :Failed to update contribution in database, but the actual error "Authorization Failed" is coming from https://github.com/civicrm/civicrm-core/commit/62a721eda743ba248cf3b1a571a83f5fdbc72a56#diff-7a5b0e2d131dabc49178460fc63328c0R4430
Why you don't see the actual error is a separate weirdness, i.e. why does the api throw an exception on successful transactions, and even if that's ok, then why throw a new exception when caught - just rethrow the actual $e so that you can see the actual error.