Russel88 / MAGinator

MAGinator - Accurate SNV calling and profiling of MAGs
MIT License
16 stars 1 forks source link

Snakemake workflow "inconsistent use of tabs and spaces in indentation" error ? #9

Open jnesme opened 10 months ago

jnesme commented 10 months ago

Hi Jakob ! Trying to run the handy snakemake from reads to bins in MAGinator but I am soon hitting this problem which seems to be an odd Pythin syntax error :

snakemake --use-conda -s MAGinator/maginator/recommended_workflow/reads_to_bins.Snakefile --resources mem_gb=180 --config reads=reads.csv --cores 10 --printshellcmds

returns :

TabError in file <string>, line 308:
inconsistent use of tabs and spaces in indentation (<string>, line 308)
  File "/home/projects/ku_00041/apps/jnesme/miniconda3/envs/maginator/lib/python3.12/tokenize.py", line 541, in _generate_tokens_from_c_tokenizer
  File "/home/projects/ku_00041/apps/jnesme/miniconda3/envs/maginator/lib/python3.12/tokenize.py", line 537, in _generate_tokens_from_c_tokenizer

Do you have any idea if this is a simple fix or I should just run the recommended workflow stepwise ? Best, Joseph.

Russel88 commented 9 months ago

Hi Joseph! In what part of the workflow do you get this error?

jnesme commented 9 months ago

Hi Jakob, thanks a lot for taking the time to look at this ! Actually the error pops up in 4-5s after launching the above-mentioned command and the "input" I give is only the reads.csv I am working on Computerome 2.0, MAGinator is installed in its own conda env with pip and I load VAMB from computerome tools library.

Russel88 commented 9 months ago

I just pushed a commit to the dev branch that should fix it (although I haven't tested it)

jnesme commented 9 months ago

Fixed, as far as I could test (and after manually installing Biopython which is not installed by pip install maginator) - at least it's building DAG of jobs, I killed it because I was on the head node 🙈 , will submit to queue and report here.

Thanks a lot Jakob

Russel88 commented 9 months ago

Great! Yeah, we should probably remove the biopython dependency. The goal is that maginator should only have snakemake and mamba as dependencies and the rest is installed by snakemake on the fly