Skip to content

Commit

Permalink
add log file name to error panel
Browse files Browse the repository at this point in the history
  • Loading branch information
pdimens committed Aug 5, 2024
1 parent fb7670c commit fcb51b6
Show file tree
Hide file tree
Showing 22 changed files with 22 additions and 22 deletions.
2 changes: 1 addition & 1 deletion src/harpy/printfunctions.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
def print_onstart(text, title):
"""Print a panel of info on workflow run"""
print("")
print(Panel(text, title = f"[bold]Harpy {title}", title_align = "left", border_style = "light_steel_blue", subtitle = "Running Workflow", width = 75), file = sys.stderr)
print(Panel(text, title = f"[bold]harpy {title}", title_align = "left", border_style = "light_steel_blue", subtitle = "Running Workflow", width = 75), file = sys.stderr)

def print_error(errortext):
"""Print a yellow panel with error text"""
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/align_bwa.smk
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy align bwa",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/align_ema.smk
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy align ema",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/align_strobealign.smk
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy align strobealign",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/deconvolve.smk
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy deconvolve",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/demultiplex_gen1.smk
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy demultiplex",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/impute.smk
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ onerror:
print("")
rprint(
Panel(
"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy impute",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/phase.smk
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy phase",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/preflight_bam.smk
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy preflight bam",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/preflight_fastq.smk
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy preflight fastq",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/qc.smk
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy qc",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/simulate_linkedreads.smk
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy simulate reads",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/simulate_snpindel.smk
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy simulate snpindel",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/simulate_variants.smk
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = f"[bold]harpy simulate {variant}",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/snp_freebayes.smk
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy snp freebayes",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/snp_mpileup.smk
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy snp mpileup",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/sv_leviathan.smk
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy sv leviathan",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/sv_leviathan_pop.smk
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy sv leviathan",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/sv_naibr.smk
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy sv naibr",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/sv_naibr_phase.smk
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy sv naibr",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/sv_naibr_pop.smk
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy sv naibr",
title_align = "left",
border_style = "red"
Expand Down
2 changes: 1 addition & 1 deletion src/harpy/snakefiles/sv_naibr_pop_phase.smk
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ onerror:
print("")
rprint(
Panel(
f"The workflow has terminated due to an error. See the log file below for more details.",
f"The workflow has terminated due to an error. See the log file for more details:\n[bold]{outdir}/logs/snakemake/{dt_string}.snakelog[/bold]",
title = "[bold]harpy sv naibr",
title_align = "left",
border_style = "red"
Expand Down

0 comments on commit fcb51b6

Please sign in to comment.