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

Inspection: validate that rule defines all required input/output/params/etc keys for wrapper #224

Open
iromeo opened this issue Aug 23, 2019 · 2 comments
Labels
inspections Code inspections
Milestone

Comments

@iromeo
Copy link
Contributor

iromeo commented Aug 23, 2019

Inspection: validate that rule defines all required input/output/params/etc keys for wrapper

Wrappers contain meta.yaml and it has information about input, output, params, etc args. We could validate that our rule defines all these params. E.g.

# tool/meta.yaml
arguments:
   input:
        fq: Smth about input fastq file
        index: Smth about index
    output:
        bam: Smth about bam
        report: Smath about report
        stats: Some optional stats
             - optional
     params:
        extra: Some description
            - optional

Than for rule:

rule foo:
   input: 
        fq = ".."
   output:
       bam = ".."
   params:
       eextra = ".."
   wrapper: '../../../tool'

We could inform user, that in input section required argument index is missing, in output argument report is missing, in params section eextra is unexpected element.

@iromeo
Copy link
Contributor Author

iromeo commented Aug 23, 2019

@iromeo
Copy link
Contributor Author

iromeo commented Aug 23, 2019

Seems most popular format is smth like

name: epic
authors:
  - Endre Bakken Stovner
description: |
  Find broad enriched domains in ChIP-Seq data with epic
input:
  - treatment: chip .bed(.gz/.bz) files
  - background: input .bed(.gz/.bz) files
output:
  - enriched_regions: main output file with enriched peaks
  - bed: (optional) contains much of the same info as enriched_regions but in a bed format, suitable for viewing in the UCSC genome browser or downstream use with bedtools
  - matrix: (optional) a gzipped matrix of read counts
params:
  - extra: additional parameters
  - log: (optional) file to write the log output to
notes: |
  * All/any of the different bigwig options must be given as extra parameters

So we could add some simple inspection, which warns about missing properties from documentation or even show documentation popup for input/output/.. sections fetching some info from meta.yaml

@iromeo iromeo added the inspections Code inspections label Aug 23, 2019
@iromeo iromeo added this to the Backlog milestone Jul 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
inspections Code inspections
Projects
None yet
Development

No branches or pull requests

1 participant