stable-diffusion-webui icon indicating copy to clipboard operation
stable-diffusion-webui copied to clipboard

Check for Extension Updates in Parallel

Open Haoming02 opened this issue 1 year ago • 1 comments

Description

  • a simple description of what you're trying to accomplish: Check the updates for all Extensions at once rather than one by one
    • On my system, checking updates for a dozen Extensions now only takes around 1 second, and after applying the updates, everything still works fine.
  • a summary of changes in code: Make the for ext in exts: loop multi-threaded using the threading package

Checklist:


Though, I'm not sure if the shared.state parts should be changed or not...

Haoming02 avatar Oct 29 '24 06:10 Haoming02

somehow I feel like the possibility of requesting hundreds of fetch to github is a bad idea so I made some minor changes mainly rewriting it using ThreadPoolExecutor and setting a deafault limit of 16 and add some Atomic sections such as updating progress bar and Reporting on errors

do you think the number should be higher than 16?

fun fact I about 200 extension installed, (10 enabled, 190 disabled)


there is also the --update-all-extensions cli arg which currently is not concurrent if that is to be made concurrent I'm not sure using a setting value is a good idea

w-e-w avatar Oct 29 '24 11:10 w-e-w