nf-core / tools

Python package with helper tools for the nf-core community.
https://nf-co.re
MIT License
241 stars 190 forks source link

Allow numbers in pipeline names #3067

Open adamrtalbot opened 3 months ago

adamrtalbot commented 3 months ago

Description of feature

Currently, pipeline names do not allow numbers, even if the organisation (prefix) is not nf-core. We need to support this because many pipeline names include numbers outside of core nf-core pipelines.

awgymer commented 3 months ago

I see this has been fixed in a PR, but I think it might need some refinement. Are we sure that names which start with a number are allowed? (Groovy/java variables can't and we use the name as the name of a workflow in nextflow).

Also is - definitely now usable? I tried it previously (more than a year ago) and again some stuff in the template borked because of it in variable names.

adamrtalbot commented 3 months ago

I see this has been fixed in a PR, but I think it might need some refinement. Are we sure that names which start with a number are allowed? (Groovy/java variables can't and we use the name as the name of a workflow in nextflow).

Also is - definitely now usable? I tried it previously (more than a year ago) and again some stuff in the template borked because of it in variable names.

If you make a pipeline and you never try to run it once I think you have bigger problems than the name of your pipeline.

awgymer commented 3 months ago

I think we should aim to stop people foot-gunning themselves wherever possible - it's part of the appeal of something like nf-core.

FWIW I have confirmed that names which start with a number or hyphen/dash cause errors:

- cause: Workflow definition syntax error -- A string identifier must be provided after the `workflow` keyword @ line 79, column 9.
   workflow 2TEST {

- cause: Workflow definition syntax error -- A string identifier must be provided after the `workflow` keyword @ line 79, column 9.
   workflow TEST-2 {