Skip to content

Commit bee0a6c

Browse files
committed
Fix contig lengths
1 parent c4ecc8b commit bee0a6c

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

vcztools/vcf_writer.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -522,9 +522,7 @@ def _generate_header(
522522
)
523523

524524
# [1.4.7 Contig field format]
525-
contig_lengths = (
526-
ds.attrs["contig_lengths"] if "contig_lengths" in ds.attrs else None
527-
)
525+
contig_lengths = ds["contig_length"] if "contig_length" in ds else None
528526
for i, contig in enumerate(contigs):
529527
if contig_lengths is None:
530528
print(f"##contig=<ID={contig}>", file=output)

0 commit comments

Comments
 (0)