Skip to content

Commit

Permalink
removed smartmatch warning vep
Browse files Browse the repository at this point in the history
  • Loading branch information
MarvinDo committed Feb 22, 2024
1 parent 5b83fd3 commit f05555f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/annotation_service/annotation_jobs/vep_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ def __init__(self, job_config, refseq=False):
self.job_name = "vep ensembl"
self.refseq=refseq
self.job_config = job_config
self.err_subber = re.compile(r"Smartmatch is experimental at /.*/VEP/AnnotationSource/File.pm line 472.")


def execute(self, inpath, annotated_inpath, **kwargs):
Expand All @@ -33,7 +34,8 @@ def execute(self, inpath, annotated_inpath, **kwargs):
vep_code, vep_stderr, vep_stdout = self._annotate_vep(inpath, annotated_inpath)

## stupid workaround for this specific vep warning:
if vep_stderr == "VEP runtime WARNING: Smartmatch is experimental at /mnt/storage2/users/ahdoebm1/HerediVar/tools/ensembl-vep/modules/Bio/EnsEMBL/VEP/AnnotationSource/File.pm line 472.":
vep_stderr = re.sub(self.err_subber, "", vep_stderr)
if vep_stderr.strip() == "VEP runtime WARNING:" or vep_stderr.strip() == "VEP runtime ERROR:":
vep_stderr = ""

self.handle_result(inpath, annotated_inpath, vep_code)
Expand Down

0 comments on commit f05555f

Please sign in to comment.