
import luigi

from .active import ActiveFastaExport
from .active import SpeciesSpecificFastaExport
from .inactive import InactiveFastaExport
from .nhmmer import NHmmerIncludedExport
from .nhmmer import NHmmerExcludedExport
from .compress import CompressExport
from .readme import FastaReadme


class FastaExport(luigi.WrapperTask):
    """
    This is the main class to generate all FASTA file exports.
    """

    def requires(self):
        yield FastaReadme()
        yield CompressExport()
        yield ActiveFastaExport()
        yield InactiveFastaExport()
        yield SpeciesSpecificFastaExport()
        yield NHmmerExcludedExport()
        yield NHmmerIncludedExport()


class NHmmerExport(luigi.WrapperTask):
    """
    This does the exports required for nhmmer.
    """

    def requires(self):
        yield NHmmerExcludedExport()
        yield NHmmerIncludedExport()


import luigi

from .active import ActiveFastaExport
from .active import SpeciesSpecificFastaExport
from .inactive import InactiveFastaExport
from .nhmmer import NHmmerIncludedExport
from .nhmmer import NHmmerExcludedExport
from .compress import CompressExport
from .readme import FastaReadme


class FastaExport(luigi.WrapperTask):
    """
    This is the main class to generate all FASTA file exports.
    """

    def requires(self):
        yield FastaReadme()
        yield NHmmerExport()
        yield CompressExport()


class NHmmerExport(luigi.WrapperTask):
    """
    This does the exports required for nhmmer.
    """

    def requires(self):
        yield NHmmerExcludedExport()
        yield NHmmerIncludedExport()

Simplify the general Fasta export task
Simplify the general Fasta export task

It doesn't need to be so complicated, so we simplify it.

  
  import luigi
  
  from .active import ActiveFastaExport
  from .active import SpeciesSpecificFastaExport
  from .inactive import InactiveFastaExport
  from .nhmmer import NHmmerIncludedExport
  from .nhmmer import NHmmerExcludedExport
  from .compress import CompressExport
  from .readme import FastaReadme
  
  
  class FastaExport(luigi.WrapperTask):
      """
      This is the main class to generate all FASTA file exports.
      """
  
      def requires(self):
          yield FastaReadme()
+         yield NHmmerExport()
          yield CompressExport()
-         yield ActiveFastaExport()
-         yield InactiveFastaExport()
-         yield SpeciesSpecificFastaExport()
-         yield NHmmerExcludedExport()
-         yield NHmmerIncludedExport()
  
  
  class NHmmerExport(luigi.WrapperTask):
      """
      This does the exports required for nhmmer.
      """
  
      def requires(self):
          yield NHmmerExcludedExport()
          yield NHmmerIncludedExport()
  
Simplify the general Fasta export task
## Code Before:

import luigi

from .active import ActiveFastaExport
from .active import SpeciesSpecificFastaExport
from .inactive import InactiveFastaExport
from .nhmmer import NHmmerIncludedExport
from .nhmmer import NHmmerExcludedExport
from .compress import CompressExport
from .readme import FastaReadme


class FastaExport(luigi.WrapperTask):
    """
    This is the main class to generate all FASTA file exports.
    """

    def requires(self):
        yield FastaReadme()
        yield CompressExport()
        yield ActiveFastaExport()
        yield InactiveFastaExport()
        yield SpeciesSpecificFastaExport()
        yield NHmmerExcludedExport()
        yield NHmmerIncludedExport()


class NHmmerExport(luigi.WrapperTask):
    """
    This does the exports required for nhmmer.
    """

    def requires(self):
        yield NHmmerExcludedExport()
        yield NHmmerIncludedExport()

## Instruction:
Simplify the general Fasta export task
## Code After:

import luigi

from .active import ActiveFastaExport
from .active import SpeciesSpecificFastaExport
from .inactive import InactiveFastaExport
from .nhmmer import NHmmerIncludedExport
from .nhmmer import NHmmerExcludedExport
from .compress import CompressExport
from .readme import FastaReadme


class FastaExport(luigi.WrapperTask):
    """
    This is the main class to generate all FASTA file exports.
    """

    def requires(self):
        yield FastaReadme()
        yield NHmmerExport()
        yield CompressExport()


class NHmmerExport(luigi.WrapperTask):
    """
    This does the exports required for nhmmer.
    """

    def requires(self):
        yield NHmmerExcludedExport()
        yield NHmmerIncludedExport()
