datatracker/ietf/sync
Ole Laursen e1f0917659 Summary: Add new document saving API, Document.save_with_history(events).
The new API requires at least one event and will automatically save a
snapshot of the document and related state. Document.save() will now
throw an exception if called directly, as the new API is intended to
ensure that documents are saved with both an appropriate snapsnot and
relevant history log, both of which are easily defeated by just
calling .save() directly.

To simplify things, the snapshot is generated after the changes to a
document have been made (in anticipation of coming changes), instead
of before as was usual.

While revising the existing code to work with this API, a couple of
missing events was discovered:

- In draft expiry, a "Document has expired" event was only generated
  in case an IESG process had started on the document - now it's
  always generated, as the document changes its state in any case

- Synchronization updates like title and abstract amendmends from the
  RFC Editor were silently (except for RFC publication) applied and
  not accompanied by a descriptive event - they now are

- do_replace in the Secretariat tools now adds an event

- Proceedings post_process in the Secretariat tools now adds an event

- do_withdraw in the Secretariat tools now adds an event

A migration is needed for snapshotting all documents, takes a while to
run. It turns out that a single document had a bad foreign key so the
migration fixes that too.
 - Legacy-Id: 10101
2015-09-28 14:01:03 +00:00
..
__init__.py Revamp sync from RFC Editor to include more info, fix a couple of bugs 2012-09-17 15:45:27 +00:00
discrepancies.py Made ietf/sync pyflakes-clean. 2014-03-16 07:49:21 +00:00
iana.py Summary: Add new document saving API, Document.save_with_history(events). 2015-09-28 14:01:03 +00:00
mails.py Add POST interface for IANA/RFC Editor for triggering updates, add 2012-09-17 15:57:48 +00:00
rfceditor.py Summary: Add new document saving API, Document.save_with_history(events). 2015-09-28 14:01:03 +00:00
tests.py Summary: Add new document saving API, Document.save_with_history(events). 2015-09-28 14:01:03 +00:00
urls.py Port to new class-based generic redirect and simple template views, remove utils.lazy.reverse_lazy, it's now included in Django 2013-12-11 16:36:09 +00:00
views.py Summary: Add new document saving API, Document.save_with_history(events). 2015-09-28 14:01:03 +00:00