From 56fb5afe5fec29ba60db521f5e0864e857419585 Mon Sep 17 00:00:00 2001 From: pbashyal-nmdp Date: Mon, 13 Dec 2021 15:50:28 -0600 Subject: [PATCH 1/3] Only import openpyxl for Excel --- scripts/pyard-reduce-csv | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/scripts/pyard-reduce-csv b/scripts/pyard-reduce-csv index 40ab179..7842e98 100755 --- a/scripts/pyard-reduce-csv +++ b/scripts/pyard-reduce-csv @@ -176,13 +176,14 @@ if __name__ == '__main__': verbose = ard_config["verbose_log"] white_space_regex = re.compile(r"\s+") - try: - import openpyxl - except ImportError: - print("For Excel output, openpyxl library needs to be installed. " - "Install with:") - print(" pip install openpyxl") - sys.exit(1) + if ard_config["output_file_format"] == 'xlsx': + try: + import openpyxl + except ImportError: + print("For Excel output, openpyxl library needs to be installed. " + "Install with:") + print(" pip install openpyxl") + sys.exit(1) # Instantiate py-ard object with the latest ard = pyard.ARD() From e7bdeaf9ad465806015b14bab1e54dedbd42f62f Mon Sep 17 00:00:00 2001 From: pbashyal-nmdp Date: Mon, 24 Jan 2022 16:55:45 -0600 Subject: [PATCH 2/3] Change IMGT URL for /allelelist directory --- pyard/data_repository.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyard/data_repository.py b/pyard/data_repository.py index 181f36f..397c06e 100644 --- a/pyard/data_repository.py +++ b/pyard/data_repository.py @@ -192,7 +192,7 @@ def generate_alleles_and_xx_codes_and_who(db_connection: sqlite3.Connection, img # date: 2017-07-10 # version: IPD-IMGT/HLA 3.29.0 # origin: https://github.com/ANHIG/IMGTHLA/Allelelist.3290.txt - # repository: https://raw.githubusercontent.com/ANHIG/IMGTHLA/Latest/Allelelist.3290.txt + # repository: https://raw.githubusercontent.com/ANHIG/IMGTHLA/Latest/allelelist/Allelelist.3290.txt # author: WHO, Steven G. E. Marsh (steven.marsh@ucl.ac.uk) AlleleID,Allele HLA00001,A*01:01:01:01 @@ -228,7 +228,7 @@ def generate_alleles_and_xx_codes_and_who(db_connection: sqlite3.Connection, img if imgt_version == "Latest": allele_list_url = f'{IMGT_HLA_URL}Latest/Allelelist.txt' else: - allele_list_url = f'{IMGT_HLA_URL}Latest/Allelelist.{imgt_version}.txt' + allele_list_url = f'{IMGT_HLA_URL}Latest/allelelist/Allelelist.{imgt_version}.txt' allele_df = pd.read_csv(allele_list_url, header=6, usecols=['Allele']) # Create a set of valid alleles From 0855feb87de7fba8cd12caa62f0d9ea01d3ef22f Mon Sep 17 00:00:00 2001 From: pbashyal-nmdp Date: Mon, 24 Jan 2022 16:55:55 -0600 Subject: [PATCH 3/3] =?UTF-8?q?Bump=20version:=200.6.10=20=E2=86=92=200.6.?= =?UTF-8?q?11?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pyard/__init__.py | 2 +- setup.cfg | 2 +- setup.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pyard/__init__.py b/pyard/__init__.py index 59b08c1..143daa0 100644 --- a/pyard/__init__.py +++ b/pyard/__init__.py @@ -24,4 +24,4 @@ from .pyard import ARD __author__ = """NMDP Bioinformatics""" -__version__ = '0.6.10' +__version__ = '0.6.11' diff --git a/setup.cfg b/setup.cfg index 979da02..a59821c 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 0.6.10 +current_version = 0.6.11 commit = True tag = True diff --git a/setup.py b/setup.py index bf86ec5..0ef2ab4 100644 --- a/setup.py +++ b/setup.py @@ -42,7 +42,7 @@ setup( name='py-ard', - version='0.6.10', + version='0.6.11', description="ARD reduction for HLA with Python", long_description=readme + '\n\n' + history, author="CIBMTR",