BlafKing / sd-civitai-browser-plus

Extension to access CivitAI via WebUI: download, delete, scan for updates, list installed models, assign tags, and boost downloads with multi-threading.
GNU Affero General Public License v3.0
289 stars 44 forks source link

[Bug]: "Update Model Info & Tags" without "Overwrite" but with "Save HTML file" does not save html page for LORAs that do not have html page #255

Closed Targren closed 3 months ago

Targren commented 4 months ago

Describe the bug.

When attempting to update models to create HTML info files en masse without clobbering existing previews (see screenshot), the html files are not created for models that don't have one already, but the json files are created correctly.

Capture

Steps to reproduce the problem.

  1. Open extension
  2. Select "Lora And LoCon" model type
  3. Disable "Overwrite any existing previews, tags or descriptions." setting
  4. Enable "Save HTML file for each model when updating info & tags" setting
  5. Click "Load all installed models"
  6. Click "Update Model Info & Tags"

Expected behavior

Create HTML info files for LORAs that do not have one

System info

Console logs

Python 3.10.11 (tags/v3.10.11:7d4cc5a, Apr  5 2023, 00:38:17) [MSC v.1929 64 bit (AMD64)]
Version: v1.8.0
Commit hash: bef51aed032c0aaa5cfd80445bc4cf0d85b408b5
E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\extensions\sd-webui-controlnet\install.py:2: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
  import pkg_resources
E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\extensions\sd-webui-infinite-image-browsing\install.py:3: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
  import pkg_resources
Launching Web UI with arguments: --medvram-sdxl --xformers --api --skip-python-version-check --no-download-sd-model --no-half-vae --listen --enable-insecure-extension-access --theme dark --gradio-allowed-path E:\A1111 Web UI\StabilityMatrixData\Images
[-] ADetailer initialized. version: 23.11.1, num models: 13
CivitAI Browser+: Aria2 RPC started
ControlNet preprocessor location: E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\extensions\sd-webui-controlnet\annotator\downloads
2024-03-29 20:49:52,469 - ControlNet - INFO - ControlNet v1.1.442
2024-03-29 20:49:52,596 - ControlNet - INFO - ControlNet v1.1.442
Loading weights [4a97f316fa] from E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\Stable-diffusion\00. Favorites\arthemyReal_v10.safetensors
Creating model from config: E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\configs\v1-inference.yaml
2024-03-29 20:49:53,922 - ControlNet - INFO - ControlNet UI callback registered.
Loading VAE weights from user metadata: E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\VAE\vae-ft-mse-840000-ema-pruned.safetensors
Applying attention optimization: xformers... done.
Model loaded in 2.0s (create model: 0.3s, apply weights to model: 1.1s, load VAE: 0.1s, load textual inversion embeddings: 0.2s, calculate empty prompt: 0.1s).
Running on local URL:  http://0.0.0.0:7860

To create a public link, set `share=True` in `launch()`.
IIB Database file has been successfully backed up to the backup folder.
Startup time: 18.6s (prepare environment: 3.3s, import torch: 2.9s, import gradio: 0.8s, setup paths: 0.8s, initialize shared: 0.2s, other imports: 0.5s, list SD models: 0.1s, load scripts: 2.9s, create ui: 2.1s, gradio launch: 4.1s, add APIs: 0.6s).
Loading model 00. Favorites\Illustration\arthemyComics_v60.safetensors [b9ca0fa8a9] (2 out of 3)
Loading weights [b9ca0fa8a9] from E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\Stable-diffusion\00. Favorites\Illustration\arthemyComics_v60.safetensors
Creating model from config: E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\configs\v1-inference.yaml
Loading VAE weights from user metadata: E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\VAE\vae-ft-mse-840000-ema-pruned.safetensors
Applying attention optimization: xformers... done.
Model loaded in 18.1s (load weights from disk: 2.4s, create model: 0.2s, apply weights to model: 15.1s, load VAE: 0.3s).
CivitAI Browser+: Updated settings to: E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\ui-config.json
CivitAI Browser+: model: "VerbenaTargren.safetensors" not found on CivitAI servers.
CivitAI Browser+: Model info saved to "E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\Lora\difConsistency Set\difConsistency_darktheme.json"
CivitAI Browser+: Model info saved to "E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\Lora\difConsistency Set\difConsistency_detail.json"
CivitAI Browser+: Model info saved to "E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\Lora\difConsistency Set\difConsistency_photo.json"
CivitAI Browser+: Model info saved to "E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\LyCORIS\DownloadsToTest\PapillonCoquin.json"
CivitAI Browser+: Model info saved to "E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\LyCORIS\DownloadsToTest\SexyButterfly.json"
CivitAI Browser+: Model info saved to "E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\LyCORIS\DownloadsToTest\butterfly_Corset.json"
CivitAI Browser+: Model info saved to "E:\A1111 Web UI\StabilityMatrixData\Packages\Stable Diffusion WebUI\models\LyCORIS\DownloadsToTest\edgBlackButterfly.json"

Additional information

No response

Targren commented 4 months ago

Update: The 'api_info.json' file all seems to be wrong. It seems to repeat the same data file over and over for every LORA, as well.

BlafKing commented 4 months ago

Thanks for reporting! I'll look into the issue πŸ‘πŸ»

BlafKing commented 3 months ago

Should now be fixed in the latest version!

I'll mark this as resolved πŸ‘πŸ»