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]: #301

Closed gltchcom closed 1 month ago

gltchcom commented 1 month ago

Describe the bug.

I moved models to another drive, and now scans are failing.

My models are in H:\models\ and Forge is running on the C: drive. I am not using symlinks, but I am using command line arguments:

In webui-user.bat, I have: set COMMANDLINE_ARGS= --always-offload-from-vram --ckpt-dir "H:/models/checkpoints" --embeddings-dir "H:/models/embeddings" --lora-dir "H:/models/loras"

They are all accessible within Forge, so I know the paths are correct.

Steps to reproduce the problem.

  1. Press Update model info & tags

Expected behavior

models scan correctly

System info

Console logs

Traceback (most recent call last):
  File "C:\StableDiffusion\stable-diffusion-webui-forge\venv\lib\site-packages\gradio\routes.py", line 488, in run_predict
    output = await app.get_blocks().process_api(
  File "C:\StableDiffusion\stable-diffusion-webui-forge\venv\lib\site-packages\gradio\blocks.py", line 1431, in process_api
    result = await self.call_function(
  File "C:\StableDiffusion\stable-diffusion-webui-forge\venv\lib\site-packages\gradio\blocks.py", line 1103, in call_function
    prediction = await anyio.to_thread.run_sync(
  File "C:\StableDiffusion\stable-diffusion-webui-forge\venv\lib\site-packages\anyio\to_thread.py", line 33, in run_sync
    return await get_asynclib().run_sync_in_worker_thread(
  File "C:\StableDiffusion\stable-diffusion-webui-forge\venv\lib\site-packages\anyio\_backends\_asyncio.py", line 877, in run_sync_in_worker_thread
    return await future
  File "C:\StableDiffusion\stable-diffusion-webui-forge\venv\lib\site-packages\anyio\_backends\_asyncio.py", line 807, in run
    result = context.run(func, *args)
  File "C:\StableDiffusion\stable-diffusion-webui-forge\venv\lib\site-packages\gradio\utils.py", line 707, in wrapper
    response = f(*args, **kwargs)
  File "C:\StableDiffusion\stable-diffusion-webui-forge\extensions\sd-civitai-browser-plus\scripts\civitai_file_manage.py", line 1055, in file_scan
    save_path, name = get_save_path_and_name(install_path, file_name, api_response)
  File "C:\StableDiffusion\stable-diffusion-webui-forge\extensions\sd-civitai-browser-plus\scripts\civitai_file_manage.py", line 819, in get_save_path_and_name
    sub_folder = os.path.normpath(os.path.relpath(install_path, gl.main_folder))
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.3056.0_x64__qbz5n2kfra8p0\lib\ntpath.py", line 747, in relpath
    raise ValueError("path is on mount %r, start on mount %r" % (
ValueError: path is on mount 'H:', start on mount 'C:'

Additional information

No response

gltchcom commented 1 month ago

I'm not sure why, but when I tried it today it worked flawlessly. Closing this for now.