airr-community / airr-standards

AIRR Community Data Standards
https://docs.airr-community.org
Creative Commons Attribution 4.0 International
35 stars 23 forks source link

updated versioneer from 0.18 to 0.29 #744

Closed ssnn-airr closed 4 months ago

ssnn-airr commented 5 months ago

Hi @schristley. I have upgraded versioneer following the instructions in https://github.com/python-versioneer/python-versioneer/tree/master. I tested that the changes work in python 3.12.1 and Python 3.11.0.

schristley commented 5 months ago

Hi @ssnn-airr , thanks for this. When you say you tested, what version do you get?

I built the docker image with this branch and when I run airr-tools --version then it returns 0+unknown. My understanding is that versioneer is suppose to return a git commit version.

Python 3.8.10 (default, Nov 22 2023, 10:22:35) 
[GCC 9.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import airr
>>> from airr._version import get_versions
>>> get_versions()
{'date': None, 'dirty': None, 'error': 'unable to compute version', 'full-revisionid': None, 'version': '0+unknown'}
ssnn-airr commented 5 months ago

It seems I didn't test everything that needed testing. I used two different immcantation containers, one with python 3.12.1 and the other Python 3.11.0. I actually bumped into the versioneer issue when I tried to upgrade immcantation to Fedora 39, and I couldn't install airr.

Python 3.12.1 (main, Dec 18 2023, 00:00:00) [GCC 13.2.1 20231205 (Red Hat 13.2.1-6)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import airr
>>> from airr._version import get_versions
>>> get_versions()
{'version': '1.5.0+26.g96defdb', 'full-revisionid': '96defdbac44f27b7e525db544c5c311345e3733b', 'dirty': False, 'error': None, 'date': '2024-01-28T13:31:09+0100'}
>>> 
Python 3.11.0 (main, Oct 24 2022, 00:00:00) [GCC 12.2.1 20220819 (Red Hat 12.2.1-2)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import airr
>>> from airr._version import get_versions
>>> get_versions()
{'version': '0+unknown', 'full-revisionid': None, 'dirty': None, 'error': 'unable to compute version', 'date': None}
>>> 

The versions are not correct, but I can install airr, which is what I tested.

schristley commented 5 months ago

I think the issue is with versioneer versus the airr code. It is interesting that the one version of python gives the correct git version but the other doesn't. Anyways, I don't think it is critical for dev versions so long as the released package returns the proper version code.

ssnn-airr commented 4 months ago

@schristley will you merge this? I am not authorized to merge to master.