Confuzu / CivitAI_Image_grabber

Downloads every Image from a given CivitAi Username / Model ID / Model TAG / Model versionID
GNU General Public License v3.0
35 stars 3 forks source link

UnboundLocalError: local variable 'model_dir' referenced before assignment #6

Closed Nobrumski closed 7 months ago

Nobrumski commented 7 months ago

I am getting the following error sometimes when attempting to download via model ID. Nothing is downloaded and the folder isn't generated. This is also resulting I believe in loops being closed saying already visited even though I have nothing saved in the folder.

Traceback (most recent call last): File "X:\AI\Civitai Image Grabber\civit_image_downloader.py", line 370, in asyncio.run(main()) File "C:\Users\me\AppData\Local\Programs\Python\Python310\lib\asyncio\runners.py", line 44, in run return loop.run_until_complete(main) File "C:\Users\me\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py", line 649, in run_until_complete return future.result() File "X:\AI\Civitai Image Grabber\civit_image_downloader.py", line 352, in main results = await asyncio.gather(*tasks) File "X:\AI\Civitai Image Grabber\civit_image_downloader.py", line 244, in download_images_for_model sort_images_by_model_name(model_dir) UnboundLocalError: local variable 'model_dir' referenced before assignment

Confuzu commented 7 months ago

ok i'll take a look at it.

Confuzu commented 7 months ago

the Bug should be resolved with the new update