Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HalfDeep work in progress #51957

Merged
merged 17 commits into from
Nov 7, 2024
Merged

Conversation

richard-burhans
Copy link
Contributor

Describe your pull request here


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>.

Copy link
Contributor

coderabbitai bot commented Nov 6, 2024

📝 Walkthrough
📝 Walkthrough

Walkthrough

This pull request introduces two new files related to the "HalfDeep" package. The first file, build.sh, is a script that automates the installation of several scripts into a specified directory. It implements strict error handling, creating a binary directory and installing the scripts with defined permissions while providing feedback on any installation failures. The second file, meta.yaml, outlines the package configuration for "HalfDeep" version "0.1.0". This configuration includes essential metadata such as the package name, source URL, SHA256 checksum, runtime dependencies, build specifications, test commands, and licensing information.

Possibly related PRs

  • add recipe for sizemeup #51033: The build.sh script in this PR also automates the installation process, similar to the build.sh in the main PR, indicating a shared focus on installation automation.
  • Add hmftools-peach 2.0.0 #51150: The build.sh script for hmftools-peach shares a similar purpose of organizing files and setting permissions, which aligns with the automation goals of the main PR's build.sh.
  • Add hmftools-redux 1.0_beta #51151: Similar to the main PR, this PR introduces a build.sh script that automates the installation process, indicating a commonality in the approach to package installation.
  • Adding the devider recipe  #51365: The build.sh script in this PR also focuses on building a binary, which aligns with the automation theme present in the main PR's build.sh.
  • Add deepchopper-cli  #51780: The build.sh script in this PR automates the setup and build process, similar to the automation focus in the main PR's build.sh.
  • Update Deepchopper #51814: This PR adds a runtime requirement for deepchopper-cli, which is relevant as the main PR also focuses on installation scripts and package management.
  • Update hmftools-redux jar to fix multithreading synchronisation crash #51924: This PR addresses a specific issue related to the hmftools-redux package, which is relevant as it involves updates to package management similar to the main PR's focus on installation automation.

Suggested reviewers

  • bgruening
  • mencian

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🧹 Outside diff range and nitpick comments (2)
recipes/halfdeep/build.sh (1)

1-5: Add pipefail option for comprehensive error handling.

While the current error handling is good, adding set -o pipefail would ensure that pipeline failures are also caught, making the script more robust.

 #!/usr/bin/env bash

 set -o errexit
 set -o nounset
+set -o pipefail
 set -o xtrace
recipes/halfdeep/meta.yaml (1)

36-41: Add more package metadata

Consider adding more metadata fields to improve package discoverability.

 about:
   home: https://github.com/richard-burhans/{{ name }}
   summary: {{ name }}
   license: BSD-3-Clause
   license_file: LICENSE
   license_url: https://github.com/richard-burhans/{{ name }}/blob/master/LICENSE
+  doc_url: https://github.com/richard-burhans/{{ name }}/blob/master/README.md
+  dev_url: https://github.com/richard-burhans/{{ name }}
+  description: |
+    [Add a detailed description of the package here]
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between ed87fab and 6e343cf.

📒 Files selected for processing (2)
  • recipes/halfdeep/build.sh (1 hunks)
  • recipes/halfdeep/meta.yaml (1 hunks)
🧰 Additional context used
🪛 yamllint
recipes/halfdeep/meta.yaml

[error] 1-1: syntax error: found character '%' that cannot start any token

(syntax)

🔇 Additional comments (5)
recipes/halfdeep/build.sh (1)

7-7: LGTM!

The directory creation follows Bioconda guidelines, using the correct PREFIX variable and appropriate mkdir flags.

recipes/halfdeep/meta.yaml (4)

12-22: ⚠️ Potential issue

Add build requirements and verify dependency availability

  1. The recipe is missing build requirements section which might be needed for proper packaging.
  2. Need to verify if genodsp is available in conda channels.
#!/bin/bash
# Check if genodsp is available in conda channels
conda search genodsp --info

Add build requirements section:

 requirements:
+  build:
+    - {{ compiler('c') }}  # if C compilation is needed
+    - make  # if using make for building
   run:
     - bash
     # ... rest of run dependencies

24-28: 🛠️ Refactor suggestion

Review run_exports pinning strategy

For a 0.x.x version, the current pinning strategy might be too strict. According to Bioconda guidelines, you should adjust the pinning based on known API/ABI compatibility guarantees.

#!/bin/bash
# Check if there are any shared libraries that would require strict pinning
find . -name "*.so*" -o -name "*.dylib" -o -name "*.dll"

Consider adjusting the pinning:

   run_exports:
-    - {{ pin_subpackage('halfdeep', max_pin="x.x") }}
+    - {{ pin_subpackage('halfdeep', max_pin="x") }}  # For 0.x.x versions

9-10: Verify source checksum

The source configuration looks good, but let's verify the checksum matches the release archive.


43-45: Verify aarch64 build environment

The addition of linux-aarch64 platform looks good, but ensure that all dependencies are available for this architecture.

✅ Verification successful

Linux-aarch64 platform support looks consistent

The addition of linux-aarch64 platform is well-supported:

  • The key dependency genodsp also supports linux-aarch64 platform
  • Other dependencies are either standard Linux utilities or platform-independent packages
  • Both packages use the same build configuration with skip: True # [not linux]
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check if key dependencies are available for aarch64
conda search --platform linux-aarch64 genodsp

Length of output: 120


Script:

#!/bin/bash
# Let's check the recipe dependencies and build requirements
cat recipes/halfdeep/meta.yaml

Length of output: 933


Script:

#!/bin/bash
# Let's check if the key dependencies are available in the repository for aarch64
# We'll check the main dependencies that might be architecture-specific
rg -l "linux-aarch64" recipes/genodsp/
rg -l "linux-aarch64" recipes/gawk/
rg -l "linux-aarch64" recipes/r-base/

Length of output: 248


Script:

#!/bin/bash
# Let's check the genodsp recipe since it's a key dependency and is available in the repo
cat recipes/genodsp/meta.yaml

Length of output: 947

recipes/halfdeep/build.sh Outdated Show resolved Hide resolved
recipes/halfdeep/build.sh Outdated Show resolved Hide resolved
recipes/halfdeep/meta.yaml Outdated Show resolved Hide resolved
recipes/halfdeep/meta.yaml Outdated Show resolved Hide resolved
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Outside diff range and nitpick comments (2)
recipes/halfdeep/meta.yaml (2)

8-10: Consider using .tar.gz instead of .zip archive.

While both formats work, .tar.gz is the preferred format for Unix systems and is more commonly used in Bioconda recipes.

-  url: https://github.com/richard-burhans/{{ name }}/archive/refs/tags/{{ version }}.zip
+  url: https://github.com/richard-burhans/{{ name }}/archive/refs/tags/{{ version }}.tar.gz

34-39: Add recommended metadata fields.

Consider adding these fields to improve package discoverability:

 about:
   home: https://github.com/richard-burhans/{{ name }}
   summary: Automated detection of intervals covered at half depth by sequenced reads.
   license: BSD-3-Clause
   license_file: LICENSE
   license_url: https://github.com/richard-burhans/{{ name }}/blob/master/LICENSE
+  description: |
+    [Add a longer description of the tool here]
+  dev_url: https://github.com/richard-burhans/{{ name }}
+  doc_url: https://github.com/richard-burhans/{{ name }}#readme
+  tags:
+    - genomics
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 6e343cf and 63bc591.

📒 Files selected for processing (2)
  • recipes/halfdeep/build.sh (1 hunks)
  • recipes/halfdeep/meta.yaml (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • recipes/halfdeep/build.sh
🧰 Additional context used
🪛 yamllint
recipes/halfdeep/meta.yaml

[error] 1-1: syntax error: found character '%' that cannot start any token

(syntax)

🔇 Additional comments (2)
recipes/halfdeep/meta.yaml (2)

1-6: LGTM! Package metadata is well-structured.

The package name and version are properly defined using Jinja2 templating, with correct lowercasing of the package name.

🧰 Tools
🪛 yamllint

[error] 1-1: syntax error: found character '%' that cannot start any token

(syntax)


30-32: Previous test coverage comment is still applicable.

recipes/halfdeep/meta.yaml Outdated Show resolved Hide resolved
recipes/halfdeep/meta.yaml Outdated Show resolved Hide resolved
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 63bc591 and 50263ef.

📒 Files selected for processing (2)
  • recipes/halfdeep/build.sh (1 hunks)
  • recipes/halfdeep/meta.yaml (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • recipes/halfdeep/build.sh
🧰 Additional context used
🪛 yamllint
recipes/halfdeep/meta.yaml

[error] 1-1: syntax error: found character '%' that cannot start any token

(syntax)

🔇 Additional comments (4)
recipes/halfdeep/meta.yaml (4)

1-6: LGTM! Package metadata follows best practices.

The package name and version are properly templated, with correct lowercasing of the package name.

🧰 Tools
🪛 yamllint

[error] 1-1: syntax error: found character '%' that cannot start any token

(syntax)


36-41: LGTM! About section is complete and well-documented.

All required metadata fields are present with proper licensing information and a descriptive summary.


8-10: Consider using .tar.gz instead of .zip for the source.

While both formats work, .tar.gz is the preferred format for source distributions in the Linux/Unix ecosystem and is typically smaller in size.

Let's verify the checksum and availability of both archive formats:

#!/bin/bash
# Check if .tar.gz is available and compare with .zip
curl -sI "https://github.com/richard-burhans/HalfDeep/archive/refs/tags/0.1.0.tar.gz"
echo "Verifying provided checksum..."
curl -sL "https://github.com/richard-burhans/HalfDeep/archive/refs/tags/0.1.0.zip" | sha256sum

12-24: 🛠️ Refactor suggestion

Add version constraints for bioinformatics tools.

While the previous review covered Python and R constraints, it's also important to specify minimum versions for bioinformatics tools to ensure compatibility:

     - gawk
-    - genodsp
+    - genodsp >=1.0
     - grep
     - gzip
-    - minimap2
+    - minimap2 >=2.24
     - python
     - r
-    - samtools
+    - samtools >=1.15
     - sed

Let's verify the genodsp dependency:

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Outside diff range and nitpick comments (1)
recipes/halfdeep/meta.yaml (1)

1-7: Consider package naming consistency

The package name is defined in uppercase (HalfDeep) but used in lowercase. While the |lower filter handles this, it's better to define it in lowercase initially for consistency.

-{% set name = "HalfDeep" %}
+{% set name = "halfdeep" %}
🧰 Tools
🪛 yamllint

[error] 1-1: syntax error: found character '%' that cannot start any token

(syntax)

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 50263ef and 7c19cd5.

📒 Files selected for processing (1)
  • recipes/halfdeep/meta.yaml (1 hunks)
🧰 Additional context used
🪛 yamllint
recipes/halfdeep/meta.yaml

[error] 1-1: syntax error: found character '%' that cannot start any token

(syntax)

Comment on lines 13 to 25
requirements:
run:
- bash
- coreutils
- gawk
- genodsp
- grep
- gzip
- minimap2
- python >={{ minimum_python_version }}
- r-base >={{ r_base }}
- samtools
- sed
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Add version constraints for bioinformatics tools

Critical tools like minimap2 and samtools should have version constraints to ensure reproducibility. Also, verify that the r_base variable is defined.

    - minimap2
+    - minimap2 >=2.24
    - python >={{ minimum_python_version }}
    - r-base >={{ r_base }}
    - samtools
+    - samtools >=1.15

Committable suggestion skipped: line range outside the PR's diff.

recipes/halfdeep/meta.yaml Show resolved Hide resolved
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Outside diff range and nitpick comments (2)
recipes/halfdeep/meta.yaml (2)

9-10: Consider using .tar.gz instead of .zip for the source archive

Using .tar.gz is preferred for Unix systems and is the standard format for most Conda packages. It typically provides better compression and preserves Unix file permissions.

-  url: https://github.com/richard-burhans/{{ name }}/archive/refs/tags/{{ version }}.zip
+  url: https://github.com/richard-burhans/{{ name }}/archive/refs/tags/{{ version }}.tar.gz

32-34: Consider adding test files

While command verification is good, consider adding:

  1. Test data files to verify actual functionality
  2. Test that input/output formats are handled correctly

Add test files section:

test:
  files:
    - test-data/sample.bam  # Example BAM file for testing
    - test-data/expected_output.txt  # Expected output for validation
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 7c19cd5 and b02dd8d.

📒 Files selected for processing (1)
  • recipes/halfdeep/meta.yaml (1 hunks)
🧰 Additional context used
🪛 yamllint
recipes/halfdeep/meta.yaml

[error] 1-1: syntax error: found character '%' that cannot start any token

(syntax)

🔇 Additional comments (2)
recipes/halfdeep/meta.yaml (2)

13-24: Verify completeness of runtime dependencies

The dependencies look reasonable, but please verify:

  1. Are there any R packages required beyond r-base?
  2. Are there any Python packages required beyond the interpreter?
  3. Do any of the scripts use other Unix tools not listed here?

1-41: Verify Bioconda-specific requirements

Please ensure the recipe follows Bioconda guidelines:

  1. Add host: section if any compilation is needed
  2. Consider adding extra: section with:
    • Recipe maintainer information
    • Links to upstream issues/PRs
    • DOI for citation
🧰 Tools
🪛 yamllint

[error] 1-1: syntax error: found character '%' that cannot start any token

(syntax)

@bgruening bgruening merged commit efb39ac into bioconda:master Nov 7, 2024
6 checks passed
@coderabbitai coderabbitai bot mentioned this pull request Nov 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants