Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test+Docker profile fails: Can't locate object method "cdna_coords" #611

Open
Oliversinn opened this issue Sep 13, 2024 · 3 comments
Open
Labels
bug Something isn't working

Comments

@Oliversinn
Copy link

Oliversinn commented Sep 13, 2024

Description of the bug

ERROR ~ Error executing process > 'NFCORE_RAREDISEASE:RAREDISEASE:ANNOTATE_STRUCTURAL_VARIANTS:ENSEMBLVEP_SV (justhusky)'

Caused by:
  Process `NFCORE_RAREDISEASE:RAREDISEASE:ANNOTATE_STRUCTURAL_VARIANTS:ENSEMBLVEP_SV (justhusky)` terminated with an error exit status (255)


Command executed:

  vep \
      -i justhusky_view.vcf \
      -o justhusky_svdbquery_vep.vcf.gz \
      --dir_cache vep_cache --dir_plugins vep_cache/Plugins --plugin pLI,pLI_values.txt --appris --biotype --buffer_size 100 --canonical --cache --ccds --compress_output bgzip --distance 5000 --domains --exclude_predicted --force_overwrite --format vcf --fork 4 --hgvs --humdiv --max_sv_size 248956422 --merged --no_progress --numbers --per_gene --polyphen p --protein --offline --regulatory --sift p --symbol --tsl --uniprot --vcf \
       \
      --fasta reference.fasta \
      --assembly GRCh37 \
      --species homo_sapiens \
      --cache \
      --cache_version 107 \
      --dir_cache ${PWD}/vep_cache \
      --fork 2
  
  
  cat <<-END_VERSIONS > versions.yml
  "NFCORE_RAREDISEASE:RAREDISEASE:ANNOTATE_STRUCTURAL_VARIANTS:ENSEMBLVEP_SV":
      ensemblvep: $( echo $(vep --help 2>&1) | sed 's/^.*Versions:.*ensembl-vep : //;s/ .*$//')
  END_VERSIONS

Command exit status:
  255

Command output:
  2024-09-13 21:02:40 - INFO: BAM-edited cache detected, enabling --use_transcript_ref; use --use_given_ref to override this

Command error:
  2024-09-13 21:02:40 - INFO: BAM-edited cache detected, enabling --use_transcript_ref; use --use_given_ref to override this
  Can't locate object method "cdna_coords" via package "Bio::EnsEMBL::Variation::StructuralVariationOverlap" at /usr/local/share/ensembl-vep-112.0-0/Bio/EnsEMBL/Variation/Utils/VariationEffect.pm line 673.
  Died in forked process 2112

Work dir:
  /home/tecniscan/Data/work/08/6ec046f9e7bea0a665d4ba8b2ae23c

Tip: view the complete command output by changing to the process work dir and entering the command `cat .command.out`

 -- Check '.nextflow.log' file for details
ERROR ~ Pipeline failed. Please refer to troubleshooting docs: https://nf-co.re/docs/usage/troubleshooting

 -- Check '.nextflow.log' file for details

Command used and terminal output

nextflow run nf-core/raredisease -profile test,docker --outdir results

Relevant files

nextflow.log

System information

Nextflow version: 24.04.4 build 5917
Hardware: Desktop
Executor: local
Container engine: Docker
OS: Linux Mint 22
Version of nf-core/raredisease: v2.2.0-gfa61a65

@Oliversinn Oliversinn added the bug Something isn't working label Sep 13, 2024
@jemten
Copy link
Collaborator

jemten commented Sep 16, 2024

Thanks for reporting @Oliversinn,
looks like an issue with annotating breakpoint variants in VEP, Ensembl/ensembl-vep#1694 (comment). Looks like it will be patched in the next release of VEP (113). For now the workaround seems to be to remove the --regulatory flag in the ENSEMBLVEP_SV process config. We will test that change and patch the pipeline.

@jemten
Copy link
Collaborator

jemten commented Sep 18, 2024

Yes, you would have to remove the --regulatory flag from the ENSEMBLVEP_SV process in this file conf/modules/annotate_structural_variants.configconf/modules/annotate_structural_variants.config even when running with you data,

@Oliversinn
Copy link
Author

Oliversinn commented Sep 19, 2024

Now I am getting the following:

-[nf-core/raredisease] Pipeline completed with errors-
ERROR ~ Error executing process > 'NFCORE_RAREDISEASE:RAREDISEASE:ANN_CSQ_PLI_SV:ADD_MOST_SEVERE_CSQ (justhusky)'

Caused by:
  Process `NFCORE_RAREDISEASE:RAREDISEASE:ANN_CSQ_PLI_SV:ADD_MOST_SEVERE_CSQ (justhusky)` terminated with an error exit status (1)


Command executed:

  add_most_severe_consequence.py --file_in justhusky_svdbquery_vep.vcf.gz --file_out justhusky_sv_csq_research.vcf --variant_csq variant_consequences_v2.txt
  
  cat <<-END_VERSIONS > versions.yml
  "NFCORE_RAREDISEASE:RAREDISEASE:ANN_CSQ_PLI_SV:ADD_MOST_SEVERE_CSQ":
      add_most_severe_consequence: v1.0
      python: $(python --version | sed 's/Python //g')
  END_VERSIONS

Command exit status:
  1

Command output:
  (empty)

Command error:
  Traceback (most recent call last):
    File "/home/tecniscan/.nextflow/assets/nf-core/raredisease/bin/add_most_severe_consequence.py", line 192, in <module>
      sys.exit(main())
    File "/home/tecniscan/.nextflow/assets/nf-core/raredisease/bin/add_most_severe_consequence.py", line 188, in main
      write_csq_annotated_vcf(in_vcf, out_vcf, var_csq)
    File "/home/tecniscan/.nextflow/assets/nf-core/raredisease/bin/add_most_severe_consequence.py", line 142, in write_csq_annotated_vcf
      mscsq = construct_most_severe_consequence_info(line, allele_ind, csq_ind, hgnc_ind, var_csq)
    File "/home/tecniscan/.nextflow/assets/nf-core/raredisease/bin/add_most_severe_consequence.py", line 75, in construct_most_severe_consequence_info
      transcripts, allele_ind, csq_ind, hgnc_ind, var_csq
  UnboundLocalError: local variable 'transcripts' referenced before assignment

Work dir:
  /home/tecniscan/Data/raredisease_test/work/3f/72d00dc5d134c5022c49a5a54582b9

Tip: when you have fixed the problem you can continue the execution adding the option `-resume` to the run command line

 -- Check '.nextflow.log' file for details
ERROR ~ Pipeline failed. Please refer to troubleshooting docs: https://nf-co.re/docs/usage/troubleshooting

 -- Check '.nextflow.log' file for details

the .command.sh file is

#!/bin/bash -euo pipefail
add_most_severe_consequence.py --file_in justhusky_svdbquery_vep.vcf.gz --file_out justhusky_sv_csq_research.vcf --variant_csq variant_consequences_v2.txt

cat <<-END_VERSIONS > versions.yml
"NFCORE_RAREDISEASE:RAREDISEASE:ANN_CSQ_PLI_SV:ADD_MOST_SEVERE_CSQ":
    add_most_severe_consequence: v1.0
    python: $(python --version | sed 's/Python //g')
END_VERSIONS

And when I manually run it throws:

bin/bash: line 0: /bin/bash: ./.command.sh: Invalid option

I found this possible solution: https://unix.stackexchange.com/questions/533415/invalid-option-name-error-with-shebang-bin-bash-o-pipefail-in-script

The weird thing is that it looks like -euo pipefail (which seems causing the problem) is set up globally for all the scripts, so why is only happening here? If I come out with a solution I'll keep you posted, but nothing so far.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants