Skip to content

Implement wave container commands#3954

Draft
JulianFlesch wants to merge 172 commits into
nf-core:devfrom
JulianFlesch:feature/3952-create-waveyml
Draft

Implement wave container commands#3954
JulianFlesch wants to merge 172 commits into
nf-core:devfrom
JulianFlesch:feature/3952-create-waveyml

Conversation

@JulianFlesch
Copy link
Copy Markdown
Contributor

@JulianFlesch JulianFlesch commented Dec 2, 2025

Closes #3952

  • nf-core modules containers create [module-name]
  • nf-core modules containers conda-lock [module-name]
  • nf-core modules containers lint [module-name]
  • nf-core modules containers list [module-name]

@ningyuxin1999 ningyuxin1999 self-assigned this Dec 2, 2025
@JulianFlesch JulianFlesch changed the title switch pre-commit to prek for development Implement wave container commands Dec 2, 2025
Comment thread nf_core/components/nfcore_component.py Outdated
Comment thread nf_core/components/nfcore_component.py Outdated
Comment thread nf_core/modules/containers.py Outdated
Comment thread nf_core/modules/containers.py Outdated
]
return containers_flat

def _resolve_module_dir(self, module: str | Path) -> Path:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

do we not have this funciton already somehwere else?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I might be overlooking something, but not really ... As far as I can tell, we have ModulesInfo, which was used at some point, but it never provides the environment.yml or meta.yml paths, or confirms their existance.

Maybe this should be in ModulesInfo?

Comment thread nf_core/modules/containers.py Outdated
return module_dir

@staticmethod
def _environment_path(module_dir: Path) -> Path:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

because we lint for this, I think we should be able to reuse something there.

Comment thread nf_core/utils.py


@contextmanager
def set_wd_tempdir() -> Generator[None, None, None]:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

this function is for sure created somewhere else already.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes, In pipeline downloads! But that version throws Download-specific errors ...
The plan was move it out of the utils.py over there into the general utils.
But now we don't use it at all anymore ...

Should we remove it again?

Comment thread nf_core/modules/containers.py Outdated
Comment thread nf_core/modules/containers.py
Comment thread nf_core/modules/containers.py Outdated
Comment thread nf_core/modules/containers.py Outdated
Comment thread nf_core/modules/containers.py Outdated
Comment thread nf_core/modules/containers.py Outdated
Comment thread nf_core/modules/containers.py Outdated
@JulianFlesch
Copy link
Copy Markdown
Contributor Author

JulianFlesch commented Dec 9, 2025

  • Test still missing ( @ningyuxin1999 )
  • Linting still missing
  • Sorting the resulting meta.yml after running create() still missing
  • Refactoring ModuleInfo to be helpful here -> TODO: ISSUE
  • Decision required: Behavior if modules don't have meta.yml and/or environment.yml

Comment thread nf_core/modules/containers.py Outdated
@codecov
Copy link
Copy Markdown

codecov Bot commented Jan 14, 2026

Codecov Report

❌ Patch coverage is 66.14173% with 301 lines in your changes missing coverage. Please review.
✅ Project coverage is 77.72%. Comparing base (03bcc65) to head (9391a3f).

Files with missing lines Patch % Lines
nf_core/modules/containers.py 71.14% 118 Missing ⚠️
nf_core/commands_modules.py 7.59% 73 Missing ⚠️
nf_core/modules/lint/module_containers.py 72.22% 40 Missing ⚠️
nf_core/components/nfcore_component.py 56.60% 23 Missing ⚠️
nf_core/modules/modules_utils.py 69.23% 20 Missing ⚠️
nf_core/modules/lint/environment_yml.py 82.25% 11 Missing ⚠️
nf_core/modules/lint/meta_yml.py 75.75% 8 Missing ⚠️
nf_core/__main__.py 83.33% 4 Missing ⚠️
nf_core/modules/bump_versions.py 0.00% 2 Missing ⚠️
nf_core/components/components_command.py 75.00% 1 Missing ⚠️
... and 1 more

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@mashehu
Copy link
Copy Markdown
Contributor

mashehu commented Jan 17, 2026

Added the meta_yml sorting now. I also switched the default value of --await to true, because it wouldn't get the singularity https links by default.

Comment thread nf_core/components/lint/__init__.py Outdated
Comment thread nf_core/components/nfcore_component.py
Comment thread nf_core/components/nfcore_component.py
Comment thread nf_core/modules/lint/__init__.py
Comment thread nf_core/modules/lint/__init__.py
Comment thread nf_core/modules/lint/meta_yml.py Outdated
Comment thread nf_core/modules/containers.py Outdated

# Load containers from meta.yml into the component before linting
meta_path = Path(self.nfcore_component.component_dir, "meta.yml")
if meta_path.exists():
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

no need for this if clause, we already check that in read_meta_yml()

Comment thread nf_core/modules/modules_utils.py Outdated
Comment thread nf_core/pipelines/lint/__init__.py
Comment thread tests/subworkflows/test_lint.py Outdated
Comment thread pyproject.toml
@mashehu mashehu force-pushed the feature/3952-create-waveyml branch 3 times, most recently from 47ed327 to b71b250 Compare March 30, 2026 08:33
mashehu added a commit to nf-core/modules that referenced this pull request May 26, 2026
via `nf-core m container create multiqc` from nf-core/tools#3954
mashehu added a commit to nf-core/modules that referenced this pull request May 26, 2026
via `nf-core m container create multiqc` from nf-core/tools#3954
matthdsm added a commit to nf-core/modules that referenced this pull request May 26, 2026
* pin build version for multiqc

* fix singularity urls

* update seqera container

via `nf-core m container create multiqc` from nf-core/tools#3954

---------

Co-authored-by: mashehu <mashehu3@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In progress

Development

Successfully merging this pull request may close these issues.

3 participants