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

Add consistency checks between installed modules and modules.json #1200

Merged
merged 7 commits into from
Jul 14, 2021

Conversation

ErikDanielsson
Copy link
Contributor

Added consistency checks between modules present in pipeline and modules.json:

  • If a module is missing from the directory but is present in the modules.json file we try to reinstall it at the given commit SHA
  • If the install fails, we remove the entry in modules.json
  • If a module is present in the directory, but missing from modules.json we try figure out the correct one using the file contents. If that fails, we continue but warn the user.

These checks are run when either nf-core modules install or nf-core modules list local are run. Should resolve #1199.

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 Jul 14, 2021

Codecov Report

Merging #1200 (6edc0fe) into dev (5b6927a) will decrease coverage by 0.62%.
The diff coverage is 33.01%.

Impacted file tree graph

@@            Coverage Diff             @@
##              dev    #1200      +/-   ##
==========================================
- Coverage   70.12%   69.49%   -0.63%     
==========================================
  Files          49       49              
  Lines        5312     5403      +91     
==========================================
+ Hits         3725     3755      +30     
- Misses       1587     1648      +61     
Impacted Files Coverage Δ
nf_core/modules/module_utils.py 45.56% <11.11%> (-1.36%) ⬇️
nf_core/modules/modules_command.py 55.38% <24.65%> (-18.39%) ⬇️
nf_core/modules/install.py 39.53% <100.00%> (+0.71%) ⬆️
nf_core/modules/list.py 69.33% <100.00%> (+0.84%) ⬆️
nf_core/modules/modules_repo.py 65.43% <100.00%> (ø)
nf_core/utils.py 84.13% <100.00%> (+0.28%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5b6927a...6edc0fe. Read the comment docs.

ErikDanielsson and others added 2 commits July 14, 2021 13:24
Co-authored-by: Harshil Patel <drpatelh@users.noreply.github.com>
Copy link
Member

@drpatelh drpatelh left a comment

Choose a reason for hiding this comment

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

LGTM! It's going to be tricky reviewing these PRs having not touched the code base for a while and with everything else I am trying to do at the mo but happy to get this in so it can be tested properly :)

Thanks @ErikDanielsson

@drpatelh drpatelh merged commit f9bc301 into nf-core:dev Jul 14, 2021
@ErikDanielsson
Copy link
Contributor Author

Thanks for the review @drpatelh!

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