[Checkins] [zopefoundation/ZODB] a6c171: Long lines. Grrrr.

GitHub noreply at github.com
Tue Jul 12 17:41:23 CEST 2016


  Branch: refs/heads/undo-refactor
  Home:   https://github.com/zopefoundation/ZODB
  Commit: a6c1713d0d78e640c7550d39fe233eb6c47d00cf
      https://github.com/zopefoundation/ZODB/commit/a6c1713d0d78e640c7550d39fe233eb6c47d00cf
  Author: Jim Fulton <jim at zope.com>
  Date:   2016-07-12 (Tue, 12 Jul 2016)

  Changed paths:
    M src/ZODB/ConflictResolution.py

  Log Message:
  -----------
  Long lines. Grrrr.


  Commit: d717a685fa69b9529867538cbb8aeebe1ac191cd
      https://github.com/zopefoundation/ZODB/commit/d717a685fa69b9529867538cbb8aeebe1ac191cd
  Author: Jim Fulton <jim at zope.com>
  Date:   2016-07-12 (Tue, 12 Jul 2016)

  Changed paths:
    M src/ZODB/FileStorage/FileStorage.py
    M src/ZODB/tests/TransactionalUndoStorage.py

  Log Message:
  -----------
  Refactored FileStorage transactional undo

As part of a project to provide object-level commit locks for ZEO, I'm
refactiring FileStorage to maintain transaction-specific data in
Tranaction.data.  This involved undo.  In trying to figure this out, I
found:

- A bug in _undoDataInfo, which I verified with some tests and

- _transactionalUndoRecord was maddeningly difficult to reason about
  (and thus change).

I was concerned less by the bug than my inability to know whether a
change to the code would be correct.

So I refactored the code, mainly transactionalUndoRecord, to make the
code easier to understand, fixing some logic errors (I'm pretty sure)
along the way.  This included lots of comments. (Comments are much
easier to compose when you're working out logic you didn't
understand.)

In addition to makeing the code cleaner, it allows undo to be handled
in cases that weren't handled before.


  Commit: d64a0cbfb19fcbd7c86ad2051ea15da6cc2ba274
      https://github.com/zopefoundation/ZODB/commit/d64a0cbfb19fcbd7c86ad2051ea15da6cc2ba274
  Author: Jim Fulton <jim at zope.com>
  Date:   2016-07-12 (Tue, 12 Jul 2016)

  Changed paths:
    M CHANGES.rst

  Log Message:
  -----------
  changes


Compare: https://github.com/zopefoundation/ZODB/compare/a6c1713d0d78^...d64a0cbfb19f


More information about the checkins mailing list