src/sv-pipeline/scripts/make_evidence_qc_table.py
This script is run as part of the EvidenceQC workflow.
Affected version(s)
[x] Latest public release version [v0.28.5-beta]
[x] Latest master branch as of [May 4, 2024]
Description
A variable is referenced before it is assigned to resulting in a UnboundLocalError and the following stacktrace:
Traceback (most recent call last):
File "/opt/sv-pipeline/scripts/make_evidence_qc_table.py", line 274, in <module>
main()
File "/opt/sv-pipeline/scripts/make_evidence_qc_table.py", line 258, in main
merge_evidence_qc_table(
File "/opt/sv-pipeline/scripts/make_evidence_qc_table.py", line 181, in merge_evidence_qc_table
df_total_high_outliers = read_all_outlier(df_manta_high_outlier, df_melt_high_outlier, df_wham_high_outlier, "high")
File "/opt/sv-pipeline/scripts/make_evidence_qc_table.py", line 152, in read_all_outlier
all_outliers_df.columns = [ID_COL, outlier_type + "_overall_outliers"]
UnboundLocalError: local variable 'all_outliers_df' referenced before assignment
The offending code attempts to set the column names of a pandas DataFrame before creating it.
Bug Report
Affected module(s) or script(s)
src/sv-pipeline/scripts/make_evidence_qc_table.py
This script is run as part of the EvidenceQC workflow.Affected version(s)
Description
A variable is referenced before it is assigned to resulting in a
UnboundLocalError
and the following stacktrace:The offending code attempts to set the column names of a pandas DataFrame before creating it.
Steps to reproduce
I don't know what this script does, but I am guessing if you run it on an input with outliers, it will error.
Expected behavior
The script should run without an
UnboundLocalError
.Actual behavior
The script exits with an
UnboundLocalError
.