Ensembl / ensembl-vep

The Ensembl Variant Effect Predictor predicts the functional effects of genomic variants
https://www.ensembl.org/vep
Apache License 2.0
444 stars 151 forks source link

VEP installation can not install Bio::DB:HTS module #1728

Closed xiyasong closed 1 month ago

xiyasong commented 1 month ago

Describe the issue

A clear and concise description of what the bug is. Hi My VEP installaztion work fine with the --NO_HTSLIB, but when I try to use it for my real sample it gives error: -------------------- EXCEPTION -------------------- MSG: ERROR: Cannot use format vcf without Bio::DB::HTS::Tabix module installed

STACK Bio::EnsEMBL::VEP::AnnotationSource::File::new /sza_data/ensembl-vep/modules/Bio/EnsEMBL/VEP/AnnotationSource/File.pm:178 STACK Bio::EnsEMBL::VEP::AnnotationSourceAdaptor::get_all_custom /sza_data/ensembl-vep/modules/Bio/EnsEMBL/VEP/AnnotationSourceAdaptor.pm:328 STACK Bio::EnsEMBL::VEP::AnnotationSourceAdaptor::get_all /sza_data/ensembl-vep/modules/Bio/EnsEMBL/VEP/AnnotationSourceAdaptor.pm:94 STACK Bio::EnsEMBL::VEP::BaseRunner::get_all_AnnotationSources /sza_data/ensembl-vep/modules/Bio/EnsEMBL/VEP/BaseRunner.pm:170 STACK Bio::EnsEMBL::VEP::Runner::init /sza_data/ensembl-vep/modules/Bio/EnsEMBL/VEP/Runner.pm:128 STACK Bio::EnsEMBL::VEP::Runner::run /sza_data/ensembl-vep/modules/Bio/EnsEMBL/VEP/Runner.pm:200 STACK toplevel ./vep:46 Date (localtime) = Thu Jul 25 17:49:56 2024 Ensembl API version = 112

So, I tried to install Bio::DB::HTS module, by running perl INSTALL.pl, then it gives error: .... gcc -o test/test-bcf-translate test/test-bcf-translate.o libhts.a -lz -lz -lm -lbz2 -llzma -lpthread

Created MYMETA.yml and MYMETA.json Creating new 'Build' script for 'Bio-DB-HTS' version '2.11' Building Bio-DB-HTS Error: no compiler detected to compile 'lib/Bio/DB/HTS.c'. Aborting ERROR: Shared Bio::DB:HTS library not found

Additional information

Please fill in the following sections to help us find the source of your issue as quickly as possible.

System

Full VEP command line

perl INSTALL.pl

Full error message

Including the warnings, if available Hello! This installer will help you set up VEP v112, including:

  • Install v112 of the Ensembl API for use by the VEP. It will not affect any existing installations of the Ensembl API that you may have.
  • Download and install cache files from Ensembl's FTP server.
  • Download FASTA files from Ensembl's FTP server.
  • Download VEP plugins.

Checking for installed versions of the Ensembl API...done

Setting up directories

If this fails, try re-running with --NO_HTSLIB

You are in 'detached HEAD' state. You can look around, make experimental changes and commit them, and you can discard any commits you make in this state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may do so (now or later) by using -c with the switch command. Example:

git switch -c

Or undo this operation with:

git switch -

Turn off this advice by setting config variable advice.detachedHead to false

Created MYMETA.yml and MYMETA.json Creating new 'Build' script for 'Bio-DB-HTS' version '2.11' Building Bio-DB-HTS Error: no compiler detected to compile 'lib/Bio/DB/HTS.c'. Aborting ERROR: Shared Bio::DB:HTS library not found

Data files (if applicable)

They include:

jamie-m-a commented 1 month ago

HI @xiyasong

Sorry to hear you've been having trouble with the install. It can be tricky to debug these issues, but there are possibly a couple of simple workarounds.

1) If you run in offline mode, using a cache and fasta file, VEP shouldn't try to use that module, so you can bypass the issue that way. So use --offline, --cache, --dir_cache and --fasta (see here for more details).

2) Failing that, you can try using the containerised docker image of Ensembl VEP - available here, with instructions here. It comes with all dependencies and plugins packaged already.

Do let me know how you get on!

xiyasong commented 1 month ago

Hi, thanks for your kind reply and suggestions, I tried --offline --cache --dir_cache seems still not solved, but luckily: I solved the problem by creating a brand new conda environment and redo everything and it magically works. :)).