sunbeam icon indicating copy to clipboard operation
sunbeam copied to clipboard

Error in rule aggregate_results

Open gooodle opened this issue 2 years ago • 7 comments

Describe the bug Hi Ulthran. I was looking for a tool which can separate metagenomic sequences, perform assembly and annotation. Your sunbeam was found the be the right fit, so I download it, installed it and tested it using a pair of pair-ended sequences. Everything went very well until annotation step. It threw an error like that posted below:

Output/logs/screenshots Error in rule aggregate_results: jobid: 2 input: path/my_project/sunbeam_output/assembly/contigs/OS00FF7A-contigs.fa output: path/my_project/sunbeam_output/annotation/summary/OS00FF7A.tsv log: path/my_project/sunbeam_output/logs/aggregate_results_OS00FF7A.log (check log file(s) for error details) conda-env: path/sunbeam4.0.0/.snakemake/9a073270401899bbdd6508b4285aee14_

RuleException: CalledProcessError in file path/sunbeam4.0.0/extensions/sbx_assembly/sbx_annotation.smk, line 217: Command 'source path/sunbeam4.0.0/.snakemake/9a073270401899bbdd6508b4285aee14_'; set -euo pipefail; python path/sunbeam4.0.0/.snakemake/scripts/tmpiz4c6whx.aggregate_results.py' returned non-zero exit status 1. File "path/sunbeam4.0.0/extensions/sbx_assembly/sbx_annotation.smk", line 217, in __rule_aggregate_results File "path/miniconda3/envs/sunbeam4.0.0/lib/python3.12/concurrent/futures/thread.py", line 58, in run Shutting down, this might take some time. Exiting because a job execution failed. Look above for error message Complete log: .snakemake/log/2023-10-27T135041.789556.snakemake.log

Sunbeam version sunbeam 4.0.0.

Additional context I am not sure if is is a bug. I hope that you could help figure out why the run led to this, and how this can be circumvented. Thanks a lot.

Chilin

gooodle avatar Oct 27 '23 19:10 gooodle

Hi @gooodle thanks for using Sunbeam! Can you check to see if there's any useful information in path/my_project/sunbeam_output/logs/aggregate_results_OS00FF7A.log? Also if you happen to have the full snakemake output from that run it would be very helpful for debugging this as well.

Charlie

Ulthran avatar Oct 30 '23 16:10 Ulthran

Thanks for your time and reply, Charlie. I checked the logs folder and found the very file, but somehow it is empty. I made a snapshot of all the files in path/my_project/sunbeam_output/logs for your reference.

Gooodle

Capture

gooodle avatar Oct 30 '23 18:10 gooodle

Thanks @gooodle, it's surprising actually that it is fully empty, there should be at least a starting message in there. Is there any way you could get the output from snakemake as well? I'm guess there's probably an error hidden somewhere in there but snakemake doesn't always make it the easiest to find.

Charlie

Ulthran avatar Oct 31 '23 00:10 Ulthran

Thanks, Charlie. I checked the log file .snakemake/log/2023-10-26T114346.984045.snakemake.log. it says: KeyError in file path/sunbeam4.0.0/extensions/sbx_assembly/sbx_annotation.smk, line 76: 'sbx_annotation' File "path/sunbeam4.0.0/workflow/Snakefile", line 128, in File "path/sunbeam4.0.0/extensions/sbx_assembly/sbx_annotation.smk", line 76, in

Is this error information helpful for diagnosis?

Gooodle

gooodle avatar Oct 31 '23 15:10 gooodle

Oh that is helpful, can you please also include the sunbeam_config.yml file for that project?

It looks like maybe it's failing to access a config option from there. If you installed the sbx_assembly extension after initializing this project, then you can probably fix the problem by running sunbeam config update -i /path/to/project/sunbeam_config.yml.

If that doesn't fix it, it would also be very helpful if you could run sunbeam again (should just try the failing rule and fail again quickly) and then include the full output of that run here.

Charlie

Ulthran avatar Oct 31 '23 16:10 Ulthran

Thanks for your quick reply, Charlie. Attached the .yml file for your reference. I ran sunbeam config update -i /path/to/project/sunbeam_config.yml, but it seemed to have not made any difference to the file content. sunbeam_config.yml.txt

Gooodle

gooodle avatar Oct 31 '23 16:10 gooodle

Yup everything looks ok there. Could you please run sunbeam again (it should just run the failing rule and fail again quickly) and then include the full output of that run here.

Ulthran avatar Oct 31 '23 21:10 Ulthran

Hi @gooodle, I'm going to close this for inactivity. If you run into this or a similar issue again please open a new issue and link this one. Both sunbeam and sbx_assembly (which includes annotation) have been updated since you encountered this issue so hopefully the problem has been resolved in those updates.

Ulthran avatar Mar 29 '24 14:03 Ulthran