
import luigi

from tasks.config import db
from tasks.config import export

from tasks.utils.files import atomic_output


class GoAnnotation(luigi.Task):
    def output(self):
        return luigi.LocalTarget(export().go('rnacentral_annotations.tsv'))

    def run(self):
        with atomic_output(self.output()) as out:
            export(db(), out)


import luigi

from tasks.config import db
from tasks.config import export

from rnacentral.export.ftp import go_terms

from tasks.utils.files import atomic_output


class GoAnnotationExport(luigi.Task):
    def output(self):
        return luigi.LocalTarget(export().go('rnacentral_annotations.tsv'))

    def run(self):
        with atomic_output(self.output()) as out:
            go_terms.export(db(), out)

Update name and call correct export
Update name and call correct export

This now calls the correct export function. Additionally, the class name
is changed to reflect it does export.

  
  import luigi
  
  from tasks.config import db
  from tasks.config import export
  
+ from rnacentral.export.ftp import go_terms
+ 
  from tasks.utils.files import atomic_output
  
  
- class GoAnnotation(luigi.Task):
+ class GoAnnotationExport(luigi.Task):
      def output(self):
          return luigi.LocalTarget(export().go('rnacentral_annotations.tsv'))
  
      def run(self):
          with atomic_output(self.output()) as out:
-             export(db(), out)
+             go_terms.export(db(), out)
  
Update name and call correct export
## Code Before:

import luigi

from tasks.config import db
from tasks.config import export

from tasks.utils.files import atomic_output


class GoAnnotation(luigi.Task):
    def output(self):
        return luigi.LocalTarget(export().go('rnacentral_annotations.tsv'))

    def run(self):
        with atomic_output(self.output()) as out:
            export(db(), out)

## Instruction:
Update name and call correct export
## Code After:

import luigi

from tasks.config import db
from tasks.config import export

from rnacentral.export.ftp import go_terms

from tasks.utils.files import atomic_output


class GoAnnotationExport(luigi.Task):
    def output(self):
        return luigi.LocalTarget(export().go('rnacentral_annotations.tsv'))

    def run(self):
        with atomic_output(self.output()) as out:
            go_terms.export(db(), out)
