Avoid needless wrapping of message in a txn.

This would imply that on the server-side, the payload `g.stopTransaction(FAILURE)`  (used to open a new, fresh, transaction context) gets wrapped in a transaction itself, meaning an implicit `g.stopTransaction(SUCCESS)` is executed on the server if that payload succeeds.

It's harmless, but useless.
Makes sure no messages sent within the context manager get wrapped in an implicit transaction itself.

In other words, it makes sure to always set `in_transaction=False` on emitted messages inside an explicitly managed transaction.

This particular bug broke pretty much all sane transaction semantics because `g.stopTransaction(SUCCESS)` would be executed after each message sent implicitly.
Makes sure transactions are properly committed or rolled back.

Depending on whether an exception occurred or not, a transaction will be committed or rolled back.  Previously, when the context manager has exited, `self.close_transaction()` was called, performing a commit on an only partially executed block.

This patch changes that to properly call `self.close_transaction(False)` when a failure happened, properly rolling back the entire transaction on the server end.