AmpliconSuite-pipeline icon indicating copy to clipboard operation
AmpliconSuite-pipeline copied to clipboard

There are some small bugs in singularity running scripts

Open panxiaoguang opened this issue 11 months ago • 1 comments

  1. If the singularity version number is a strange number like "singularity-ce version 3.11.5-1.el7", then the original function test_singularity_version will get a singularity_version like "3.11.5-1.el7", but the 5-1 is impossible to translate into int64 from a string. So I think it's a good idea to use packaging.version instead.
  2. If users get their singularity image according to your recommended command:singularity pull library://jluebeck/ampliconsuite-pipeline/ampliconsuite-pipeline, then the file name they get will be "ampliconsuite-pipeline-latest.sif". So I think it's a good idea to modify the codes for checking singularity images to make them more robust.

panxiaoguang avatar Mar 26 '24 08:03 panxiaoguang

Hi, thanks much for making this PR!

I agree the 'glob' enhancement is helpful!

Is the packaging library default with python? I believe it is not. I do not want to add more dependencies if I can avoid it. I did not realize the version string could be messy for the patch version. Since it is 3.6 or higher that is needed, I suggest modifying the PR to have similar functionality to the original code, but do not check the patch version (it is irrelevant since it needs anything over 3.6).

major, minor = map(int, singularity_version.split('.')[0:2])
assert (major, minor) >= (3, 6),'Singularity version {singularity_version} is not supported. Please upgrade to version 3.6.0 or higher.'

If this simple change still does not work for you, then please let me know and we can add packaging as a dependency to installation.

jluebeck avatar Mar 27 '24 22:03 jluebeck

Issues addressed in AmpliconSuite-pipeline v1.3.3

jluebeck avatar Jun 18 '24 23:06 jluebeck