From 889fd943c775d915ca679b450d13899b002d45ce Mon Sep 17 00:00:00 2001 From: Eli Kogan-Wang Date: Tue, 23 Jul 2024 03:45:30 +0200 Subject: [PATCH] Make preference check more general --- src/appenv.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/appenv.py b/src/appenv.py index 68ce6d1..74b28da 100755 --- a/src/appenv.py +++ b/src/appenv.py @@ -518,9 +518,10 @@ def update_lockfile(self, freeze_args=None, remaining=None): ensure_minimal_python() preferences = parse_preferences() python312_mixed_setuptools_workaround = False - if preferences is not None and '3.12' in preferences and any( - f'3.{x}' in preferences for x in range(4, 12)): - python312_mixed_setuptools_workaround = True + if preferences is not None: + if any(f'3.{x}' in preferences for x in range(4, 12)): + if any(f'3.{x}' in preferences for x in range(12, 20)): + python312_mixed_setuptools_workaround = True os.chdir(self.base) print("Updating lockfile") tmpdir = os.path.join(self.appenv_dir, "updatelock")