Prepare the list of files to be processed

def lists(self):
        """
        Prepare the list of files to be processed
        """
        # Prepare the lists to be used to classify the metagenomes
        with open(self.filelist, 'w') as filelist:
            with open(self.reportlist, 'w') as reportlist:
                for sample in self.runmetadata.samples:
                    if self.extension == 'fastq':
                        try:
                            status = sample.run.Description
                            if status == 'metagenome':
                                filelist.write(sample.general.combined + '\n')
                                reportlist.write(sample.general.combined.split('.')[0] + '\n')
                        except AttributeError:
                            pass
                    else:
                        if sample.general.combined != 'NA':
                            filelist.write(sample.general.combined + '\n')
                            reportlist.write(sample.general.combined.split('.')[0] + '\n')