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]: HTML and api_info files saving in the wrong location #263

Closed hakaserver closed 3 months ago

hakaserver commented 3 months ago

Describe the bug.

After latest bug fix, the HTML and api_info files are no longer saved in the same folder as the custom images location. I have set a custom location for saving images and have both Use sub folders inside custom images location and Store the HTML and api_info in the custom images location options enabled (I also have both options of auto download images and model info enabled).

Steps to reproduce the problem.

  1. Have the settings described above enabled.
  2. Download model, model info and images
  3. HTML and api_info files are saved in the .safetensors file location, instead of the custom images location.

Expected behavior

With the settings described and the commit 8585e67 it worked correctly, with the HTML and api_info files being saved in the correct location. After updating to last commit 033ccc2 and without changing any settings, the HTML and api_info files are now being saved in the model location (along with the .safetensors file).

The images are still being saved in the correct location and the HTML file correctly look for them, but cant find them since they are in a different base folder (I also have the local images option enabled).

System info

Console logs

[NOTICE] Download complete: D:/SDWebui/stable-diffusion-webui/models/Lora/Subfolder/model.safetensors
CivitAI Browser+: Model saved to: D:\SDWebui\stable-diffusion-webui\models\Lora\Subfolder\model.safetensors
CivitAI Browser+: Model info saved to "D:\SDWebui\stable-diffusion-webui\models\Lora\Subfolder\model.safetensors.json"
CivitAI Browser+: Saved HTML to "D:\SDWebui\stable-diffusion-webui\models\Lora\Subfolder\model.safetensors.html"
CivitAI Browser+: Preview saved at "D:\SDWebui\stable-diffusion-webui\models\Lora\Subfolder\model.preview.png"
CivitAI Browser+: Downloaded sample_0.jpg
CivitAI Browser+: Downloaded sample_1.jpg```

Additional information

The correct save location described in the console logs should have been "D:\SDWebui\stable-diffusion-webui\models_db\Lora\Subfolder\" for both 'Saved HTML and 'Model info', as per my configs.

BlafKing commented 3 months ago

Thanks for reporting!

The latest commit should fix this issue :) I'll mark this as resolved as the issue should be fixed 👍🏻