allind / EukDetect

MIT License
40 stars 15 forks source link

AttributeError: 'str' object has no attribute 'keys' #9

Closed LuzBreton closed 3 years ago

LuzBreton commented 3 years ago

Hi! I have an issue with EukDetect after the line: File "/home/breton/anaconda3/envs/eukdetect/lib/python3.6/site-packages/EukDetect-1.0.1-py3.6.egg/eukdetect/runall.py", line 365, in check_aln_output AttributeError: 'str' object has no attribute 'keys'

any idea? Thanks!

allind commented 3 years ago

Thanks for reaching out. Could you post your config file so I can see what's going on?

LuzBreton commented 3 years ago

Thanks Allind, This is my config file configfile.txt

This is my line: eukdetect --mode runall --configfile configfile.yml --cores 8 01/18/2021 10:54:58: Parsing config file ... Traceback (most recent call last): File "/home/breton/anaconda3/envs/eukdetect/bin/eukdetect", line 33, in sys.exit(load_entry_point('EukDetect==1.0.1', 'console_scripts', 'eukdetect' ) ()) File "/home/breton/anaconda3/envs/eukdetect/lib/python3.6/site-packages/EukDetect-1.0.1-py3.6.egg/runall.py", line 136, in main File "/home/breton/anaconda3/envs/eukdetect/lib/python3.6/site-packages/EukDetect-1.0.1-py3.6.egg/runall.py", line 365, in check_aln_output

allind commented 3 years ago

Great, thanks. It looks like there's some issues with your config file with respect to the fwd suffix, rev suffix, and sample names. I'm not entirely clear what your fastq file names look like from this, but here's an example that will hopefully help:

If I have 2 samples from a paired end sequencing experiment, "experiment1" and "experiment2", I would have four files:

experiment1_fwd.fastq.gz
experiment1_rev.fastq.gz
experiment2_fwd.fastq.gz
experiment2_rev.fastq.gz

In my config.yml file, I would have the following lines for the suffixes:

fwd_suffix: "_fwd.fastq.gz"
rev_suffix: "_rev.fastq.gz"

The sample portion of the config would look like this:

samples:
  experiment1:
  experiment2:

Can you try changing the config file to reflect this naming scheme? If you're not clear on what to do here, please post the names of your fastq files.

LuzBreton commented 3 years ago

sorry Allind, but I not getting it and I´m very excited to use it! I have 1 sample and two files fwd and rev S1_R1.fastq.gz S1_R2.fastq.gz

In my configfile.yml, I have the following lines for the suffixes

fwd_suffix: "S1_R1.fastq.gz" rev_suffix: "S1_R2.fastq.gz"

The sample portion of the config and follow your note inside the config should be?:

samples: S1_R1.fastq.gz:fwd_suffix S1_R2.fastq.gz:rev_suffix

Best, LBreton

allind commented 3 years ago

Okay, so you should have these lines in your configfile:

fwd_suffix: "_R1.fastq.gz"
rev_suffix: "_R2.fastq.gz"

samples:
  S1:

Please let me know if that works.

LuzBreton commented 3 years ago

Thaks Allind, it worked!