Skip to content

Commit

Permalink
Merge pull request #15705 from AUTOMATIC1111/use-script_path-for-webu…
Browse files Browse the repository at this point in the history
…i-root-in-launch_utils

use script_path for webui root in launch_utils
  • Loading branch information
AUTOMATIC1111 committed Jun 8, 2024
2 parents 74b1fc6 + f12886a commit b9dfc50
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions modules/launch_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def git_tag():
except Exception:
try:

changelog_md = os.path.join(os.path.dirname(os.path.dirname(__file__)), "CHANGELOG.md")
changelog_md = os.path.join(script_path, "CHANGELOG.md")
with open(changelog_md, "r", encoding="utf-8") as file:
line = next((line.strip() for line in file if line.strip()), "<none>")
line = line.replace("## ", "")
Expand Down Expand Up @@ -231,7 +231,7 @@ def run_extension_installer(extension_dir):

try:
env = os.environ.copy()
env['PYTHONPATH'] = f"{os.path.abspath('.')}{os.pathsep}{env.get('PYTHONPATH', '')}"
env['PYTHONPATH'] = f"{script_path}{os.pathsep}{env.get('PYTHONPATH', '')}"

stdout = run(f'"{python}" "{path_installer}"', errdesc=f"Error running install.py for extension {extension_dir}", custom_env=env).strip()
if stdout:
Expand Down

0 comments on commit b9dfc50

Please sign in to comment.