Add transaction to event slots
Fixes #232 Fixes #234
Add transaction to event slots.
This ends up a bit more complex to be able to keep a reference to the transaction in the event, this PR introduced a BaseTransaction that only keeps reference to the document and the origin (independently of the rust object).
That ensures the introspection of the event at any time.
It also introduces a more robust way to maintain the mapping of Python origin and rust origin.
Thanks for the PR, I will have a look soon.
@fcollonval Could you explain the reasoning about adding a reference count to origins?
Not using a counter will result in discarding the origin from the mapping too early.
I don't think it's the case if the transaction is dropped after removing the origin from the doc.
Closing as no feedback, feel free to reopen.