bioconda-recipes icon indicating copy to clipboard operation
bioconda-recipes copied to clipboard

Update mosdepth to 0.3.8

Open asp8200 opened this issue 2 months ago • 7 comments

Update mosdepth to 0.3.8.


Please read the guidelines for Bioconda recipes before opening a pull request (PR).

General instructions

  • If this PR adds or updates a recipe, use "Add" or "Update" appropriately as the first word in its title.
  • New recipes not directly relevant to the biological sciences need to be submitted to the conda-forge channel instead of Bioconda.
  • PRs require reviews prior to being merged. Once your PR is passing tests and ready to be merged, please issue the @BiocondaBot please add label command.
  • Please post questions on Gitter or ping @bioconda/core in a comment.

Instructions for avoiding API, ABI, and CLI breakage issues

Conda is able to record and lock (a.k.a. pin) dependency versions used at build time of other recipes. This way, one can avoid that expectations of a downstream recipe with regards to API, ABI, or CLI are violated by later changes in the recipe. If not already present in the meta.yaml, make sure to specify run_exports (see here for the rationale and comprehensive explanation). Add a run_exports section like this:

build:
  run_exports:
    - ...

with ... being one of:

Case run_exports statement
semantic versioning {{ pin_subpackage("myrecipe", max_pin="x") }}
semantic versioning (0.x.x) {{ pin_subpackage("myrecipe", max_pin="x.x") }}
known breakage in minor versions {{ pin_subpackage("myrecipe", max_pin="x.x") }} (in such a case, please add a note that shortly mentions your evidence for that)
known breakage in patch versions {{ pin_subpackage("myrecipe", max_pin="x.x.x") }} (in such a case, please add a note that shortly mentions your evidence for that)
calendar versioning {{ pin_subpackage("myrecipe", max_pin=None) }}

while replacing "myrecipe" with either name if a name|lower variable is defined in your recipe or with the lowercase name of the package in quotes.

Bot commands for PR management

Please use the following BiocondaBot commands:

Everyone has access to the following BiocondaBot commands, which can be given in a comment:

@BiocondaBot please update Merge the master branch into a PR.
@BiocondaBot please add label Add the please review & merge label.
@BiocondaBot please fetch artifacts Post links to CI-built packages/containers.
You can use this to test packages locally.

Note that the @BiocondaBot please merge command is now depreciated. Please just squash and merge instead.

Also, the bot watches for comments from non-members that include @bioconda/<team> and will automatically re-post them to notify the addressed <team>.

asp8200 avatar Apr 26 '24 06:04 asp8200

Thanks for going through this. I'd prefer to stick to nim < 2 for this as I haven't tested fully on nim 2.0+. And the OSX build would be nice to have.

brentp avatar Apr 27 '24 05:04 brentp

Thanks for going through this. I'd prefer to stick to nim < 2 for this as I haven't tested fully on nim 2.0+. And the OSX build would be nice to have.

Hi @brentp. As you may have already noticed from the commit history on this PR, I did try to set nim < v2, but that seemingly forced nim to go all the way back to v1.4.8 and osx still failed. (I guess the build process went for nim v1.4.8 in that case, because v1.6 isn't available at https://anaconda.org/conda-forge/nim/files )

Do you have any suggestions as to which version of nim I should try? Cheers

asp8200 avatar Apr 27 '24 05:04 asp8200

probably the best way is to get the binaries from here: https://github.com/nim-lang/nightlies/releases/tag/latest-version-1-6 in the recipe

brentp avatar Apr 28 '24 05:04 brentp

probably the best way is to get the binaries from here: https://github.com/nim-lang/nightlies/releases/tag/latest-version-1-6 in the recipe

Tried something. From the logs from the failing osx-build:

BIOCONDA INFO (OUT) Downloading https://github.com/nim-lang/nightlies/archive/refs/tags/2024-04-24-version-1-6-b7b3f87719a201007e5dc0730bf73141fd908c6a.zip
BIOCONDA INFO (ERR) INFO:conda_build.source:Downloading https://github.com/nim-lang/nightlies/archive/refs/tags/2024-04-24-version-1-6-b7b3f87719a201007e5dc0730bf73141fd908c6a.zip
BIOCONDA INFO (OUT) Success

which looked promising, but nevertheless nimble wasn't found during the subsequent attempted build of mosdepth:

BIOCONDA INFO (ERR) /opt/mambaforge/envs/bioconda/conda-bld/mosdepth_1714289370255/work/conda_build.sh: line 10: nimble: command not found

asp8200 avatar Apr 28 '24 08:04 asp8200

is it getting unzipped and installed by some bioconda magic? I would think you'd need to unzip and then update the path to point to the bin directory.

brentp avatar Apr 28 '24 08:04 brentp

is it getting unzipped and installed by some bioconda magic? I would think you'd need to unzip and then update the path to point to the bin directory.

I'm at a loss here. Even when trying to build nim from source, the build of mosdepth under linux worked. That seems to indicate that building nim from source does work - at least under linux 🤔

I looked at the following recipes which also seem to install some dependencies from source:

https://github.com/bioconda/bioconda-recipes/blob/master/recipes/anise_basil/meta.yaml https://github.com/bioconda/bioconda-recipes/blob/master/recipes/anise_basil/build.sh

https://github.com/bioconda/bioconda-recipes/blob/master/recipes/artic-tools/meta.yaml https://github.com/bioconda/bioconda-recipes/blob/master/recipes/artic-tools/build.sh

I don't see any unzipping of the downloaded zip-files or installing, so I kind of figured that was done by some bioconda-magic.

This commit for artic-tools seemed to be intended for fixing osx-build, and it seemingly did so by simply adding url and sha256 under source: in the meta.yaml - very much like I tried doing for this PR 🤔

asp8200 avatar Apr 28 '24 09:04 asp8200

Got the tests passing by installing osx-release of nim v1.6 in the osx-part of build.sh-file.

Seems like a pretty hacky solution 🤔 Also, I don't understand how the linux-test can pass, when I seemingly disabled the install of nim for linux? 🤔

asp8200 avatar Apr 28 '24 13:04 asp8200

Just tested this on both linux and macOs by conda-installing:

mosdepth                0.3.8  h212548b_0  bioconda

and running:

mosdepth -n --fast-mode --by 500 sample.wgs test.paired_end.sorted.bam

It worked fine - as far as I can tell.

asp8200 avatar Apr 29 '24 10:04 asp8200