nextflow-io / nextflow-io/nf-schema

Make validateParameters function assigns (optionally) default values defined in the schema

Open
#35 1 comment 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Groovy
Stars
57
Forks
31
Avg merge
3d 17h
Merged PRs (30d)
1

Description

Hi,

ValidateParameters will not define default values in case an option is null. As a results one need to write the default value at 2 places, in the config and in the schema without anything in place to sync it, this could be misleading in case only 1 value is changed in a future version of a pipeline.

I would suggest to add an option to the function that would set default values defined in the schema so that default values are defined and enforced from a single file.

I did not find anything related to this in the other issues, sorry if I missed something and if there is already something similar in place.

Bests,

Contributor guide

No contributing guide indexed for this repository

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

Start by locating the ValidateParameters function and reviewing how schema defaults are currently handled when an option is null. Define the optional behavior so schema defaults can be applied without changing existing validation behavior, and verify the result with the project’s validation tests if available.

Written by the indexing model from the issue text.

Assessment

Tech stack
groovy
Domain
tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.