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

keyerror for sample ID #18

Open
Ruonan0101 opened this issue Dec 11, 2018 · 1 comment
Open

keyerror for sample ID #18

Ruonan0101 opened this issue Dec 11, 2018 · 1 comment

Comments

@Ruonan0101
Copy link

Ruonan0101 commented Dec 11, 2018

Hi,
I try to pass some paired end fastq files in the perseq pipeline and specify the full path in the config file but get the InputFunctionException in line 250 of the Snakefile and the KeyError: <Uniq_sampleID>_multi_multi..not sure why the 'multi' is appended and generate a wired key. Did I miss something and how can I correct this? Thanks~

  File "/home/wuru978/miniconda3/lib/python3.6/site-packages/snakemake/rules.py", line 621, in expand_input
    mapping=mapping)
  File "/home/wuru978/miniconda3/lib/python3.6/site-packages/snakemake/rules.py", line 564, in _apply_wildcards
    item = self.apply_input_function(item, wildcards, **aux_params)
  File "/home/wuru978/miniconda3/lib/python3.6/site-packages/snakemake/rules.py", line 542, in apply_input_function
    raise InputFunctionException(e, rule=self, wildcards=wildcards)
snakemake.exceptions.InputFunctionException: KeyError: 'WD_27_S15_L002_001_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi'
Wildcards:
sample=WD_27_S15_L002_001_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi

InputFunctionException in line 253 of /home/wuru978/Parseq/perseq/Snakefile:
KeyError: 'WD_27_S15_L002_001_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi'
Wildcards:
sample=WD_27_S15_L002_001_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi_multi
unlocking
removed all locks
@colinbrislawn
Copy link

Hi @Ruonan0101 ,

I think this looping issue is also described over here :

The advice is to either constrain the wildcard, or, even better, use a prefix for the output that is different from the input.

So maybe L381 and the other rule could be changed so that _multi is a prefix, not a suffix. Maybe this would work:

"gene_catalog/prodigal/multi_{sample}.faa"  

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants