diff --git a/CHANGELOG.md b/CHANGELOG.md index e07d750..156585b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,8 @@ ### Fixed + - Fixed NG50 bug that couldn't process "-" + ### Changed ## [0.11.3] diff --git a/prp/models/metadata.py b/prp/models/metadata.py index 62a0785..6b81a7d 100644 --- a/prp/models/metadata.py +++ b/prp/models/metadata.py @@ -3,7 +3,7 @@ from enum import Enum from typing import Optional -from pydantic import BaseModel, Field +from pydantic import BaseModel from .base import RWModel diff --git a/prp/models/qc.py b/prp/models/qc.py index b1af46c..b6025c8 100644 --- a/prp/models/qc.py +++ b/prp/models/qc.py @@ -7,6 +7,12 @@ from .typing import TypingSoftware +class ValidQualityStr(Enum): + """Valid strings for qc entries.""" + + LOWCONTIGQUAL = "-" + + class QcSoftware(Enum): """Valid tools.""" @@ -24,7 +30,7 @@ class QuastQcResult(BaseModel): largest_contig: int n_contigs: int n50: int - ng50: int | None = None + ng50: int | ValidQualityStr | None = None assembly_gc: float reference_gc: float | None = None duplication_ratio: float | None = None