remove shared option for update check (because it is not an argument of webui)
have launch.py examine both COMMANDLINE_ARGS as well as argv for its arguments
This commit is contained in:
parent
4c605c5174
commit
433a7525c1
2 changed files with 9 additions and 11 deletions
19
launch.py
19
launch.py
|
@ -127,13 +127,14 @@ def prepare_enviroment():
|
|||
codeformer_commit_hash = os.environ.get('CODEFORMER_COMMIT_HASH', "c5b4593074ba6214284d6acd5f1719b6c5d739af")
|
||||
blip_commit_hash = os.environ.get('BLIP_COMMIT_HASH', "48211a1594f1321b00f14c9f7a5b4813144b2fb9")
|
||||
|
||||
args = shlex.split(commandline_args)
|
||||
sys.argv += shlex.split(commandline_args)
|
||||
|
||||
args, skip_torch_cuda_test = extract_arg(args, '--skip-torch-cuda-test')
|
||||
args, reinstall_xformers = extract_arg(args, '--reinstall-xformers')
|
||||
xformers = '--xformers' in args
|
||||
deepdanbooru = '--deepdanbooru' in args
|
||||
ngrok = '--ngrok' in args
|
||||
sys.argv, skip_torch_cuda_test = extract_arg(sys.argv, '--skip-torch-cuda-test')
|
||||
sys.argv, reinstall_xformers = extract_arg(sys.argv, '--reinstall-xformers')
|
||||
sys.argv, update_check = extract_arg(sys.argv, '--update-check')
|
||||
xformers = '--xformers' in sys.argv
|
||||
deepdanbooru = '--deepdanbooru' in sys.argv
|
||||
ngrok = '--ngrok' in sys.argv
|
||||
|
||||
try:
|
||||
commit = run(f"{git} rev-parse HEAD").strip()
|
||||
|
@ -180,12 +181,10 @@ def prepare_enviroment():
|
|||
|
||||
run_pip(f"install -r {requirements_file}", "requirements for Web UI")
|
||||
|
||||
sys.argv += args
|
||||
|
||||
if '--update-check' in args:
|
||||
if update_check:
|
||||
version_check(commit)
|
||||
|
||||
if "--exit" in args:
|
||||
if "--exit" in sys.argv:
|
||||
print("Exiting because of --exit argument")
|
||||
exit(0)
|
||||
|
||||
|
|
|
@ -76,7 +76,6 @@ parser.add_argument("--disable-console-progressbars", action='store_true', help=
|
|||
parser.add_argument("--enable-console-prompts", action='store_true', help="print prompts to console when generating with txt2img and img2img", default=False)
|
||||
parser.add_argument('--vae-path', type=str, help='Path to Variational Autoencoders model', default=None)
|
||||
parser.add_argument("--disable-safe-unpickle", action='store_true', help="disable checking pytorch models for malicious code", default=False)
|
||||
parser.add_argument("--update-check", action='store_true', help="enable http check to confirm that the currently running version is the most recent release.", default=False)
|
||||
|
||||
cmd_opts = parser.parse_args()
|
||||
restricted_opts = [
|
||||
|
|
Loading…
Reference in a new issue