Method is_empty() can be determined if there have no been changes to the transaction.
There are some corner cases where keys with two parts are needed for a transaction. Relaxed the assertion and sanity check so that at least two key parts are needed for each key which is assigned to a transaction.