From e04eead569693565edb810e6f70a6d6e9b0d040e Mon Sep 17 00:00:00 2001 From: Adrian Manteza Date: Wed, 23 Mar 2022 13:12:16 +0000 Subject: [PATCH] this should be max --- app/helpers/solver_helper.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/helpers/solver_helper.py b/app/helpers/solver_helper.py index 9e20be0..aa6444c 100644 --- a/app/helpers/solver_helper.py +++ b/app/helpers/solver_helper.py @@ -48,7 +48,7 @@ def build_constraints(solver_run: SolverRun, problem: LpProblem, [ con[item.id] * items[item.id] for item in solver_run.unbundled_items() ] - ) <= round(total_form_items * (min / 100)), f'{attribute.id} - {attribute.value} - max' + ) <= round(total_form_items * (max / 100)), f'{attribute.id} - {attribute.value} - max' elif attribute.type == 'bundle': logging.info('Bundles Constraint Generating...') # TODO: account for many different bundle types, since the id condition in L33 could yield duplicates