qiime/qiime — pull request #1278 by wasade (2013-12-10 19:28:22+00:00)
Title: Workflow object

New core workflow object to support sequence processing. This object is designed to be subclassed with minimal pain (ie, no methods need be overridden). Workflow methods themselves can:

* (optionally) avoid execution if a the state is failed
* executed only if required options are met
* be prioritized

The order of the methods executed is based on an assigned priority, where a high value means it is executed first. Only those methods that are actually necessary based on runtime parameters will be evaluated. In addition, state is tracked as to simplify summary details about a run.

The ``__call__`` method yields results that can optionally go through a success or failure callback in the case that the implementation desires more than simply setting ``self.FinalState``.

This approach strongly encourages a high level of decomposition, and enforces a common API for all methods in the workflow. As construction of the iterator is performed outside of ``__call__``, arbitrarily complex iterators can be made.

@walterst and I are going to start migrating ``quality_filter_fasta`` to use this object.

Last, this code does not import any GPL code and has been put under BSD. @gregcaporaso @rob-knight, we do not currently dual license QIIME (AFAIK), see any issues here?