From 9ee487d0cff3d850eb76c432f81611bf62782041 Mon Sep 17 00:00:00 2001 From: Elijah DeLee Date: Tue, 30 Jul 2024 13:35:56 -0400 Subject: [PATCH] Min value should be Decimal This hopefully resolves error message seen in logs sometimes about "should be Decimal type" --- awx/main/models/ha.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/awx/main/models/ha.py b/awx/main/models/ha.py index 8c8c9f919b66..a061a638f692 100644 --- a/awx/main/models/ha.py +++ b/awx/main/models/ha.py @@ -160,7 +160,7 @@ def __str__(self): default=100, editable=False, ) - capacity_adjustment = models.DecimalField(default=Decimal(1.0), max_digits=3, decimal_places=2, validators=[MinValueValidator(0)]) + capacity_adjustment = models.DecimalField(default=Decimal(1.0), max_digits=3, decimal_places=2, validators=[MinValueValidator(Decimal(0.0))]) enabled = models.BooleanField(default=True) managed_by_policy = models.BooleanField(default=True)