mirror of
https://github.com/ArchipelagoMW/Archipelago.git
synced 2026-07-11 21:09:52 -07:00
ModuleUpdate: Add core requirements.txt as a constraint file to pip calls (#6309)
* Add core requirements.txt as a constraint file to pip calls * remove --upgrade as requested * Update ModuleUpdate.py
This commit is contained in:
+4
-3
@@ -38,7 +38,8 @@ class RequirementsSet(set):
|
||||
|
||||
|
||||
local_dir = os.path.dirname(__file__)
|
||||
requirements_files = RequirementsSet((os.path.join(local_dir, 'requirements.txt'),))
|
||||
core_constraints = os.path.join(local_dir, 'requirements.txt')
|
||||
requirements_files = RequirementsSet((core_constraints,))
|
||||
|
||||
if not update_ran:
|
||||
for entry in os.scandir(os.path.join(local_dir, "worlds")):
|
||||
@@ -69,7 +70,7 @@ def confirm(msg: str):
|
||||
def update_command():
|
||||
check_pip()
|
||||
for file in requirements_files:
|
||||
subprocess.call([sys.executable, "-m", "pip", "install", "-r", file, "--upgrade"])
|
||||
subprocess.call([sys.executable, "-m", "pip", "install", "-r", file, "--constraint", core_constraints])
|
||||
|
||||
|
||||
def install_pkg_resources(yes=False):
|
||||
@@ -79,7 +80,7 @@ def install_pkg_resources(yes=False):
|
||||
check_pip()
|
||||
if not yes:
|
||||
confirm("pkg_resources not found, press enter to install it")
|
||||
subprocess.call([sys.executable, "-m", "pip", "install", "--upgrade", "setuptools>=75,<81"])
|
||||
subprocess.call([sys.executable, "-m", "pip", "install", "setuptools>=75,<81"])
|
||||
|
||||
|
||||
def update(yes: bool = False, force: bool = False) -> None:
|
||||
|
||||
Reference in New Issue
Block a user