if the input handler returns a tuple (Table, md5_str) then it works, except
for --suppress_md5_sum. There is no reason the input handlers can't be more
complex though, and be objects with state instead of just functions... are
required options evaluated prior to optional options?


On Thu, Aug 15, 2013 at 12:30 PM, Jai Ram Rideout
<notifications@github.com>wrote:

> In python-code/biom/commands/summarize_biom_table.py:
>
> > +__credits__ = ["Greg Caporaso"]
> > +__license__ = "GPL"
> > +__version__ = "1.1.2-dev"
> > +__maintainer__ = "Greg Caporaso"
> > +__email__ = "gregcaporaso@gmail.com"
> > +
> > +class SummarizeBiomTable(Command):
> > +    """
> > +     Example usage:
> > +      from biom.commands.summarize_biom_table import SummarizeBiomTable
> > +      from biom.parse import parse_biom_table
> > +      c = SummarizeBiomTable()
> > +      t = parse_biom_table(open("table.biom"))
> > +      result = c(table=t)
> > +      result = c(table=t,qualitative=True)
> > +      result = c(table=t,qualitative=True,input_fp="table.biom")
>
> I don't think it would work because from the user's standpoint, they are
> only providing a single input table via --input_fp or something. This table
> simultaneously needs to be parsed into a biom.Table and passed to the
> Command, and also tied to a separate option (with no parameter) that opens
> the file and computes the MD5. And somewhere in there the
> --suppress_md5_sum option needs to be respected, and the MD5 (if it was
> computed) need to be added to the output summary.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/biom-format/biom-format/pull/161/files#r5796505>
> .
>