Skip to content

Commit

Permalink
Remove check for BCBio ImportError
Browse files Browse the repository at this point in the history
This made sense when it was added (in c6a9b24)
but is not necessary now since all installation options (pip, Bioconda)
should automatically install bcbio-gff as a dependency of Augur.

The check gave potential for inaccurate error messages such as when an
ImportError within the BCBio package is raised¹.

¹ #1151 (comment)
  • Loading branch information
victorlin committed Feb 24, 2023
1 parent 8437dcf commit 3327084
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions augur/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,11 +152,7 @@ def load_features(reference, feature_names=None):
features = {}
if '.gff' in reference.lower():
#looks for 'gene' and 'gene' as best for TB
try:
from BCBio import GFF #Package name is confusing - tell user exactly what they need!
except ImportError:
print("ERROR: Package BCBio.GFF not found! Please install using \'pip install bcbio-gff\' before re-running.")
return None
from BCBio import GFF
limit_info = dict( gff_type = ['gene', 'source'] )

with open(reference, encoding='utf-8') as in_handle:
Expand Down

0 comments on commit 3327084

Please sign in to comment.