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

nf-core modules list works on pipeline repos as well as module repos #2418

Open
wants to merge 3 commits into
base: dev
Choose a base branch
from

Conversation

adamrtalbot
Copy link
Contributor

@adamrtalbot adamrtalbot commented Sep 11, 2023

Handles case where nf-core modules list would not work on pipeline repos because of missing org_path value in nf-core YAML file. In theory, this should work regardless of the nf-core definitions as long as the structure of the repository looks like nf-core, e.g. ./modules/local/....

This now uses the existing utility function to retrieve the organisation automatically and should provide a prompt if it is missing. I haven't updated the tests but they do not appear to cover this use case so I should.

I did try to harmonise SyncedRepo class to be more consistent everywhere but there are a number of circular dependencies that appear very quickly and this would take longer than I have right now. There are multiple copy-pasted uses of methods in this class so we should resolve this.

Fixes #2417

PR checklist

  • This comment contains a description of changes (with reason)
  • CHANGELOG.md is updated
  • If you've fixed a bug or added code that should be tested, add tests!
  • Documentation in docs is updated

@codecov
Copy link

codecov bot commented Sep 19, 2023

Codecov Report

Attention: Patch coverage is 75.00000% with 1 line in your changes missing coverage. Please review.

Project coverage is 71.11%. Comparing base (32bd8c5) to head (56fa2e9).
Report is 1 commits behind head on dev.

Current head 56fa2e9 differs from pull request most recent head fb24d75

Please upload reports for the commit fb24d75 to get more accurate results.

Files Patch % Lines
nf_core/synced_repo.py 50.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##              dev    #2418      +/-   ##
==========================================
- Coverage   76.07%   71.11%   -4.97%     
==========================================
  Files          81       87       +6     
  Lines        9155     9427     +272     
==========================================
- Hits         6965     6704     -261     
- Misses       2190     2723     +533     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@mirpedrol mirpedrol left a comment

Choose a reason for hiding this comment

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

LGTM when all tests pass, thanks for the fix!

@mirpedrol
Copy link
Member

There are multiple copy-pasted uses of methods in this class so we should resolve this.

I would leave this for a different PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants