human
Here's a good function header given the following:
I wrote the below code

    (htmls, report_fnames, report_sectionlabels) = ([], [], [])
    def _update_html(html, report_fname, report_sectionlabel):
        'Update    the    lists    above.'
        htmls.append(html)
        report_fnames.append(report_fname)
        report_sectionlabels.append(report_sectionlabel)
    for fname in fnames:
        logger.info(('Rendering    :    %s' % op.join(('...' + report.data_path[(-20):]), fname)))
        try:
            if fname.endswith(('raw.fif', 'raw.fif.gz', 'sss.fif', 'sss.fif.gz')):
                html = report._render_raw(fname)
                report_fname = fname
                report_sectionlabel = 'raw'
            elif fname.endswith(('-fwd.fif', '-fwd.fif.gz')):
                html = report._render_forward(fname)
                report_fname = fname
                report_sectionlabel = 'forward'
            elif fname.endswith(('-inv.fif', '-inv.fif.gz')):
                html = report._render_inverse(fname)
                report_fname = fname
                report_sectionlabel = 'inverse'
            elif fname.endswith(('-ave.fif', '-ave.fif.gz')):
                if (cov is not None):
                    html = report._render_whitened_evoked(fname, cov, baseline, image_format)
                    report_fname = (fname + '    (whitened)')
                    report_sectionlabel = 'evoked'
                    _update_html(html, report_fname, report_sectionlabel)
                html = report._render_evoked(fname, baseline, image_format)
                report_fname = fname
                report_sectionlabel = 'evoked'
            elif fname.endswith(('-eve.fif', '-eve.fif.gz')):
                html = report._render_eve(fname, sfreq, image_format)
                report_fname = fname
                report_sectionlabel = 'events'
            elif fname.endswith(('-epo.fif', '-epo.fif.gz')):
                html = report._render_epochs(fname, image_format)
                report_fname = fname
                report_sectionlabel = 'epochs'
            elif...

What's a good function header?
assistant
#Here's a good function header.

def _iterate_files(report, fnames, info, cov, baseline, sfreq, on_error, image_format):