nf-core / nf-core/tools

`modules update` with `patch` deletes files in `templates`

Open
#3,157 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Python
Stars
322
Forks
255
Avg merge
2d 3h
Merged PRs (30d)
5

Description

Description of the bug

I customised the multiqc module to have a templates folder.
I then applied nf-core modules patch which generates a diff file for the main.nf
If I then run nf-core modules update multiqc the templates folder is removed.

Command used and terminal output
1. Add templates folder to module
2. nf-core modules patch
3. nf-core modules update multiqc
4. "Preview diff in terminal, choose whether to update files":

INFO     'modules/nf-core/multiqc/tests/tags.yml' is unchanged                                                                                                                                                                                                                                            
INFO     'modules/nf-core/multiqc/templates/custom.ipynb' was removed                                                                                                                                                                                                                                     
INFO     'modules/nf-core/multiqc/templates/custom_multiqc.py' was removed
System information

nf-core/tools version 2.14.2.dev0

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the reported sequence with nf-core modules patch followed by nf-core modules update multiqc, using the issue's terminal output as the expected failure. Trace the module patch and update handling for custom templates files; done means updating the module preserves that folder and its files.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli, tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.