vladmandic / automatic

SD.Next: Advanced Implementation of Stable Diffusion and other Diffusion-based generative image models
https://github.com/vladmandic/automatic
GNU Affero General Public License v3.0
5.61k stars 411 forks source link

[Issue]: Expecting value: line 2 column 1 (char 1) #1751

Closed Rollbacke closed 1 year ago

Rollbacke commented 1 year ago

Issue Description

Clone of the git with git clone https://github.com/vladmandic/automatic. There is nothing in my homedir. Nothing running.

I launch the webui.sh for the first time, without any argument, I get :

user@server:~/automatic$ ./webui.sh 
Create and activate python venv
Launching launch.py...
09:19:17-260588 INFO     Starting SD.Next                                                                                                                                                                          
09:19:17-264426 INFO     Python 3.10.6 on Linux                                                                                                                                                                    
09:19:17-268721 INFO     Version: 0a083c24 Tue Jul 18 20:43:30 2023 -0400                                                                                                                                          
09:19:17-335771 INFO     nVidia CUDA toolkit detected                                                                                                                                                              
09:19:17-336574 INFO     Installing package: torch torchvision --index-url https://download.pytorch.org/whl/cu118                                                                                                  
09:21:07-340019 INFO     Verifying requirements                                                                                                                                                                    
09:21:07-341053 INFO     Installing package: addict                                                                                                                                                                
09:21:10-988999 INFO     Installing package: aenum                                                                                                                                                                 
09:21:13-556744 INFO     Installing package: aiohttp                                                                                                                                                               
09:21:35-504923 INFO     Installing package: anyio                                                                                                                                                                 
09:21:44-374219 INFO     Installing package: appdirs                                                                                                                                                               
09:21:46-477865 INFO     Installing package: astunparse                                                                                                                                                            
09:21:47-650990 INFO     Installing package: bitsandbytes                                                                                                                                                          
09:21:51-826421 INFO     Installing package: blendmodes                                                                                                                                                            
09:21:52-997529 INFO     Installing package: clean-fid                                                                                                                                                             
09:21:57-428667 INFO     Installing package: easydev                                                                                                                                                               
09:21:58-936396 INFO     Installing package: extcolors                                                                                                                                                             
09:22:00-002292 INFO     Installing package: facexlib                                                                                                                                                              
09:22:09-887776 INFO     Installing package: filetype                                                                                                                                                              
09:22:10-825195 INFO     Installing package: future                                                                                                                                                                
09:22:12-062845 INFO     Installing package: gdown                                                                                                                                                                 
09:22:13-495204 INFO     Installing package: gfpgan                                                                                                                                                                
09:22:28-571594 INFO     Installing package: GitPython                                                                                                                                                             
09:22:29-988516 INFO     Installing package: httpcore                                                                                                                                                              
09:22:31-245946 INFO     Installing package: inflection                                                                                                                                                            
09:22:32-298230 INFO     Installing package: jsonmerge                                                                                                                                                             
09:22:34-688391 INFO     Installing package: kornia                                                                                                                                                                
09:22:36-291931 INFO     Installing package: lark                                                                                                                                                                  
09:22:40-547196 INFO     Installing package: lmdb                                                                                                                                                                  
09:22:42-009562 INFO     Installing package: lpips                                                                                                                                                                 
09:22:43-249172 INFO     Installing package: omegaconf                                                                                                                                                             
09:22:44-750477 INFO     Installing package: open-clip-torch                                                                                                                                                       
09:22:49-563210 INFO     Installing package: opencv-contrib-python                                                                                                                                                 
09:22:52-759510 INFO     Installing package: piexif                                                                                                                                                                
09:22:54-134961 INFO     Installing package: psutil                                                                                                                                                                
09:22:55-672335 INFO     Installing package: pyyaml                                                                                                                                                                
09:22:56-920899 INFO     Installing package: realesrgan                                                                                                                                                            
09:22:58-931481 INFO     Installing package: resize-right                                                                                                                                                          
09:23:00-215012 INFO     Installing package: rich                                                                                                                                                                  
09:23:01-579357 INFO     Installing package: safetensors                                                                                                                                                           
09:23:02-897121 INFO     Installing package: scipy                                                                                                                                                                 
09:23:04-348675 INFO     Installing package: tb_nightly                                                                                                                                                            
09:23:06-185655 INFO     Installing package: toml                                                                                                                                                                  
09:23:07-425791 INFO     Installing package: torchdiffeq                                                                                                                                                           
09:23:08-766891 INFO     Installing package: torchsde                                                                                                                                                              
09:23:10-486498 INFO     Installing package: voluptuous                                                                                                                                                            
09:23:11-742497 INFO     Installing package: yapf                                                                                                                                                                  
09:23:12-955616 INFO     Installing package: scikit-image                                                                                                                                                          
09:23:14-318458 INFO     Installing package: basicsr                                                                                                                                                               
09:23:15-677171 INFO     Installing package: compel                                                                                                                                                                
09:23:23-024056 INFO     Installing package: fasteners                                                                                                                                                             
09:23:26-279492 INFO     Installing package: pyarrow==11.0.0                                                                                                                                                       
09:23:30-315646 INFO     Installing package: typing-extensions==4.7.1                                                                                                                                              
09:23:32-256326 INFO     Installing package: antlr4-python3-runtime==4.9.3                                                                                                                                         
09:23:33-842887 INFO     Installing package: requests==2.31.0                                                                                                                                                      
09:23:35-579857 INFO     Installing package: tqdm==4.65.0                                                                                                                                                          
09:23:37-313082 INFO     Installing package: accelerate==0.20.3                                                                                                                                                    
09:23:39-235589 INFO     Installing package: opencv-python==4.7.0.72                                                                                                                                               
09:23:42-641903 INFO     Installing package: diffusers==0.18.2                                                                                                                                                     
09:23:44-275236 INFO     Installing package: einops==0.4.1                                                                                                                                                         
09:23:46-096465 INFO     Installing package: gradio==3.32.0                                                                                                                                                        
09:23:59-342099 INFO     Installing package: numexpr==2.8.4                                                                                                                                                        
09:24:01-338422 INFO     Installing package: numpy==1.23.5                                                                                                                                                         
09:24:05-450628 INFO     Installing package: numba==0.57.0                                                                                                                                                         
09:24:09-370427 INFO     Installing package: pandas==1.5.3                                                                                                                                                         
09:24:16-791231 INFO     Installing package: protobuf==3.20.3                                                                                                                                                      
09:24:18-848686 INFO     Installing package: pytorch_lightning==1.9.4                                                                                                                                              
09:24:22-173506 INFO     Installing package: transformers==4.30.2                                                                                                                                                  
09:24:28-646069 INFO     Installing package: tomesd==0.1.3                                                                                                                                                         
09:24:30-698402 INFO     Installing package: urllib3==1.26.15                                                                                                                                                      
09:24:33-243472 INFO     Installing package: Pillow==9.5.0                                                                                                                                                         
09:24:35-853458 INFO     Installing package: timm==0.6.13                                                                                                                                                          
09:24:39-072856 INFO     Installing package: pydantic==1.10.11                                                                                                                                                     
09:24:41-416537 INFO     Verifying packages                                                                                                                                                                        
09:24:41-418044 INFO     Installing package: git+https://github.com/openai/CLIP.git                                                                                                                                
09:24:45-233116 INFO     Installing package: git+https://github.com/patrickvonplaten/invisible-watermark.git@remove_onnxruntime_depedency                                                                          
09:24:49-867673 INFO     Installing package: onnxruntime==1.15.1                                                                                                                                                   
09:24:52-672408 INFO     Installing package: pi-heif                                                                                                                                                               
09:24:55-111982 INFO     Installing package: tensorflow==2.12.0                                                                                                                                                    
09:25:20-790642 INFO     Verifying repositories                                                                                                                                                                    
09:25:20-791954 INFO     Cloning repository: https://github.com/Stability-AI/stablediffusion.git                                                                                                                   
09:25:26-978992 INFO     Cloning repository: https://github.com/CompVis/taming-transformers.git                                                                                                                    
09:25:54-124294 INFO     Cloning repository: https://github.com/crowsonkb/k-diffusion.git                                                                                                                          
09:25:57-525150 INFO     Cloning repository: https://github.com/sczhou/CodeFormer.git                                                                                                                              
09:26:03-022549 INFO     Cloning repository: https://github.com/salesforce/BLIP.git                                                                                                                                
09:26:07-409670 INFO     Verifying submodules                                                                                                                                                                      
09:27:13-760178 INFO     Extension installed packages: sd-webui-controlnet ['lxml==4.9.3', 'reportlab==4.0.4', 'pycparser==2.21', 'portalocker==2.7.0', 'cffi==1.15.1', 'svglib==1.5.1', 'tinycss2==1.2.1',        
                         'mediapipe==0.10.2', 'tabulate==0.9.0', 'cssselect2==0.7.0', 'webencodings==0.5.1', 'sounddevice==0.4.6', 'iopath==0.1.9', 'yacs==0.1.8', 'fvcore==0.1.5.post20221221']                   
09:27:18-950434 INFO     Extension installed packages: stable-diffusion-webui-rembg ['rembg==2.0.38', 'pooch==1.7.0', 'PyMatting==1.1.8']                                                                          
09:27:23-972552 INFO     Extension installed packages: stable-diffusion-webui-images-browser ['xxhash==3.2.0', 'datasets==2.13.1', 'Send2Trash==1.8.2', 'image-reward==1.5', 'multiprocess==0.70.14',              
                         'fairscale==0.4.13', 'dill==0.3.6']                                                                                                                                                       
09:27:26-497827 INFO     Extension installed packages: clip-interrogator-ext ['clip-interrogator==0.6.0']                                                                                                          
09:27:31-180013 INFO     Extension installed packages: sd-webui-agent-scheduler ['SQLAlchemy==2.0.19', 'greenlet==2.0.2']                                                                                          
09:27:31-181202 INFO     Extensions enabled: ['ScuNET', 'sd-webui-controlnet', 'stable-diffusion-webui-rembg', 'sd-dynamic-thresholding', 'Lora', 'LDSR', 'stable-diffusion-webui-images-browser',                 
                         'multidiffusion-upscaler-for-automatic1111', 'clip-interrogator-ext', 'sd-extension-system-info', 'SwinIR', 'a1111-sd-webui-lycoris', 'sd-webui-agent-scheduler']                         
09:27:31-182419 INFO     Verifying packages                                                                                                                                                                        
09:27:31-188023 INFO     Extension preload: 0.0s /home/user/automatic/extensions-builtin                                                                                                                   
09:27:31-188850 INFO     Extension preload: 0.0s /home/user/automatic/extensions                                                                                                                           
09:27:31-215693 INFO     Server arguments: []                                                                                                                                                                      
No module 'xformers'. Proceeding without it.
09:27:37-146770 INFO     Pipeline: Backend.ORIGINAL                                                                                                                                                                
09:27:38-163347 INFO     Libraries loaded                                                                                                                                                                          
09:27:38-164856 INFO     Using data path: /home/user/automatic                                                                                                                                             
09:27:38-165883 INFO     Available VAEs: /home/user/automatic/models/VAE 0                                                                                                                                 
09:27:38-167053 INFO     Available models: /home/user/automatic/models/Stable-diffusion 0                                                                                                                  
Download the default model? (y/N) y
Downloading: "https://huggingface.co/runwayml/stable-diffusion-v1-5/resolve/main/v1-5-pruned-emaonly.safetensors" to /home/user/automatic/models/Stable-diffusion/v1-5-pruned-emaonly.safetensors

100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.97G/3.97G [00:12<00:00, 329MB/s]
09:31:00-996376 INFO     ControlNet v1.1.233                                                                                                                                                                       
ControlNet v1.1.233
ControlNet preprocessor location: /home/user/automatic/extensions-builtin/sd-webui-controlnet/annotator/downloads
09:31:01-168415 INFO     ControlNet v1.1.233                                                                                                                                                                       
ControlNet v1.1.233
Image Browser: Creating database
Image Browser: Database created
09:31:20-905150 INFO     Loading UI theme: name=black-orange style=Auto                                                                                                                                            
╭─────────────────────────────────────────────────────────────────────────────────────── Traceback (most recent call last) ───────────────────────────────────────────────────────────────────────────────────────╮
│ /home/user/automatic/launch.py:191 in <module>                                                                                                                                                          │
│                                                                                                                                                                                                                 │
│   190                                                                                                                                                                                                           │
│ ❱ 191     instance = start_server(immediate=True, server=None)                                                                                                                                                  │
│   192     while True:                                                                                                                                                                                           │
│                                                                                                                                                                                                                 │
│ /home/user/automatic/launch.py:144 in start_server                                                                                                                                                      │
│                                                                                                                                                                                                                 │
│   143         else:                                                                                                                                                                                             │
│ ❱ 144             server = server.webui(restart=not immediate)                                                                                                                                                  │
│   145     if args.profile:                                                                                                                                                                                      │
│                                                                                                                                                                                                                 │
│ /home/user/automatic/webui.py:317 in webui                                                                                                                                                              │
│                                                                                                                                                                                                                 │
│   316     start_common()                                                                                                                                                                                        │
│ ❱ 317     start_ui()                                                                                                                                                                                            │
│   318     modules.sd_models.write_metadata()                                                                                                                                                                    │
│                                                                                                                                                                                                                 │
│ /home/user/automatic/webui.py:264 in start_ui                                                                                                                                                           │
│                                                                                                                                                                                                                 │
│   263     global local_url # pylint: disable=global-statement                                                                                                                                                   │
│ ❱ 264     app, local_url, share_url = shared.demo.launch( # app is FastAPI(Starlette) instance                                                                                                                  │
│   265         share=cmd_opts.share,                                                                                                                                                                             │
│                                                                                                                                                                                                                 │
│ /home/user/automatic/venv/lib/python3.10/site-packages/gradio/blocks.py:1806 in launch                                                                                                                  │
│                                                                                                                                                                                                                 │
│   1805         if _frontend and (not networking.url_ok(self.local_url)) and (not self.share):                                                                                                                   │
│ ❱ 1806             raise ValueError(                                                                                                                                                                            │
│   1807                 "When localhost is not accessible, a shareable link must be created. Ple                                                                                                                 │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
ValueError: When localhost is not accessible, a shareable link must be created. Please set share=True or check your proxy settings to allow access to localhost.

I launch the webui.sh with the argument --share requested and --listen --debug (I'm on the same network), I get :

user@server:~/automatic$ ./webui.sh --share --listen --debug
Create and activate python venv
Launching launch.py...
09:32:45-210593 INFO     Starting SD.Next                                                                                                                                                                          
09:32:45-214547 INFO     Python 3.10.6 on Linux                                                                                                                                                                    
09:32:45-217948 INFO     Version: 0a083c24 Tue Jul 18 20:43:30 2023 -0400                                                                                                                                          
09:32:45-407449 DEBUG    Setting environment tuning                                                                                                                                                                
09:32:45-408510 DEBUG    Torch overrides: cuda=False rocm=False ipex=False diml=False                                                                                                                              
09:32:45-409451 DEBUG    Torch allowed: cuda=True rocm=True ipex=True diml=True                                                                                                                                    
09:32:45-410384 INFO     nVidia CUDA toolkit detected                                                                                                                                                              
09:32:45-423281 WARNING  Modified files: ['modules/lycoris']                                                                                                                                                       
09:32:45-426387 DEBUG    Repository update time: Wed Jul 19 00:43:30 2023                                                                                                                                          
09:32:45-427221 DEBUG    Previous setup time: Wed Jul 19 09:27:31 2023                                                                                                                                             
09:32:45-428060 INFO     Enabled extensions-builtin: ['ScuNET', 'sd-webui-controlnet', 'stable-diffusion-webui-rembg', 'sd-dynamic-thresholding', 'Lora', 'LDSR', 'stable-diffusion-webui-images-browser',         
                         'multidiffusion-upscaler-for-automatic1111', 'clip-interrogator-ext', 'sd-extension-system-info', 'SwinIR', 'a1111-sd-webui-lycoris', 'sd-webui-agent-scheduler']                         
09:32:45-429848 INFO     Enabled extensions: []                                                                                                                                                                    
09:32:45-430577 DEBUG    Latest extensions time: Wed Jul 19 09:31:21 2023                                                                                                                                          
09:32:45-431398 DEBUG    Timestamps: version:1689727410 setup:1689758851 extension:1689759081                                                                                                                      
09:32:45-432222 INFO     Verifying requirements                                                                                                                                                                    
09:32:45-446175 INFO     Verifying packages                                                                                                                                                                        
09:32:45-447957 INFO     Verifying repositories                                                                                                                                                                    
09:32:45-450170 DEBUG    Submodule: /home/user/automatic/repositories/stable-diffusion-stability-ai / main                                                                                                 
09:32:46-116996 DEBUG    Submodule: /home/user/automatic/repositories/taming-transformers / master                                                                                                         
09:32:46-618436 DEBUG    Submodule: /home/user/automatic/repositories/k-diffusion / master                                                                                                                 
09:32:47-383803 DEBUG    Submodule: /home/user/automatic/repositories/BLIP / main                                                                                                                          
09:32:47-816929 INFO     Verifying submodules                                                                                                                                                                      
09:32:48-099199 DEBUG    Submodule: extensions-builtin/a1111-sd-webui-lycoris / main                                                                                                                               
09:32:48-104352 DEBUG    Submodule: extensions-builtin/clip-interrogator-ext / main                                                                                                                                
09:32:48-108925 DEBUG    Submodule: extensions-builtin/multidiffusion-upscaler-for-automatic1111 / main                                                                                                            
09:32:48-113712 DEBUG    Submodule: extensions-builtin/sd-dynamic-thresholding / master                                                                                                                            
09:32:48-118266 DEBUG    Submodule: extensions-builtin/sd-extension-system-info / main                                                                                                                             
09:32:48-123068 DEBUG    Submodule: extensions-builtin/sd-webui-agent-scheduler / main                                                                                                                             
09:32:48-127856 DEBUG    Submodule: extensions-builtin/sd-webui-controlnet / main                                                                                                                                  
09:32:48-135133 DEBUG    Submodule: extensions-builtin/stable-diffusion-webui-images-browser / main                                                                                                                
09:32:48-141377 DEBUG    Submodule: extensions-builtin/stable-diffusion-webui-rembg / master                                                                                                                       
09:32:48-145972 DEBUG    Submodule: modules/lora / main                                                                                                                                                            
09:32:48-169361 DEBUG    Submodule: modules/lycoris / main                                                                                                                                                         
09:32:48-177290 DEBUG    Submodule: wiki / master                                                                                                                                                                  
09:32:48-232918 DEBUG    Installed packages: 225                                                                                                                                                                   
09:32:48-233733 DEBUG    Extensions all: ['ScuNET', 'sd-webui-controlnet', 'stable-diffusion-webui-rembg', 'sd-dynamic-thresholding', 'Lora', 'LDSR', 'stable-diffusion-webui-images-browser',                     
                         'multidiffusion-upscaler-for-automatic1111', 'clip-interrogator-ext', 'sd-extension-system-info', 'SwinIR', 'a1111-sd-webui-lycoris', 'sd-webui-agent-scheduler']                         
09:32:48-293144 DEBUG    Running extension installer: /home/user/automatic/extensions-builtin/sd-webui-controlnet/install.py                                                                               
09:32:48-482484 DEBUG    Running extension installer: /home/user/automatic/extensions-builtin/stable-diffusion-webui-rembg/install.py                                                                      
09:32:48-817323 DEBUG    Running extension installer: /home/user/automatic/extensions-builtin/stable-diffusion-webui-images-browser/install.py                                                             
09:32:53-928159 DEBUG    Running extension installer: /home/user/automatic/extensions-builtin/clip-interrogator-ext/install.py                                                                             
09:32:58-281939 DEBUG    Running extension installer: /home/user/automatic/extensions-builtin/sd-extension-system-info/install.py                                                                          
09:32:58-564128 DEBUG    Running extension installer: /home/user/automatic/extensions-builtin/sd-webui-agent-scheduler/install.py                                                                          
09:32:58-756169 DEBUG    Extensions all: []                                                                                                                                                                        
09:32:58-757081 INFO     Extensions enabled: ['ScuNET', 'sd-webui-controlnet', 'stable-diffusion-webui-rembg', 'sd-dynamic-thresholding', 'Lora', 'LDSR', 'stable-diffusion-webui-images-browser',                 
                         'multidiffusion-upscaler-for-automatic1111', 'clip-interrogator-ext', 'sd-extension-system-info', 'SwinIR', 'a1111-sd-webui-lycoris', 'sd-webui-agent-scheduler']                         
09:32:58-758204 INFO     Verifying packages                                                                                                                                                                        
09:32:58-760051 DEBUG    Setup complete without errors: 1689759179                                                                                                                                                 
09:32:58-762149 INFO     Extension preload: 0.0s /home/user/automatic/extensions-builtin                                                                                                                   
09:32:58-763031 INFO     Extension preload: 0.0s /home/user/automatic/extensions                                                                                                                           
09:32:58-770755 DEBUG    Memory used: 0.04 total: 62.79 Collected 0                                                                                                                                                
09:32:58-771734 DEBUG    Starting module: <module 'webui' from '/home/user/automatic/webui.py'>                                                                                                            
09:32:58-772633 INFO     Server arguments: ['--share', '--listen', '--debug']                                                                                                                                      
09:32:58-780481 DEBUG    Loading Torch                                                                                                                                                                             
09:33:02-390756 DEBUG    Loading Gradio                                                                                                                                                                            
09:33:03-265908 DEBUG    Loading Modules                                                                                                                                                                           
No module 'xformers'. Proceeding without it.
09:33:04-068308 DEBUG    Reading: /home/user/automatic/config.json len=233                                                                                                                                 
09:33:04-070175 INFO     Pipeline: Backend.ORIGINAL                                                                                                                                                                
09:33:04-071195 DEBUG    Loaded styles: /home/user/automatic/styles.csv 0                                                                                                                                  
09:33:04-687912 DEBUG    Samplers enumerated: ['UniPC', 'DDIM', 'PLMS', 'Euler a', 'Euler', 'DPM++ 2S a', 'DPM++ 2S a Karras', 'DPM++ 2M', 'DPM++ 2M Karras', 'DPM++ SDE', 'DPM++ SDE Karras', 'DPM++ 2M SDE',     
                         'DPM++ 2M SDE Karras', 'DPM fast', 'DPM adaptive', 'DPM2', 'DPM2 Karras', 'DPM2 a', 'DPM2 a Karras', 'LMS', 'LMS Karras', 'Heun']                                                         
09:33:04-703082 INFO     Libraries loaded                                                                                                                                                                          
09:33:04-704264 DEBUG    Entering start sequence                                                                                                                                                                   
09:33:04-712090 DEBUG    Version: {'app': 'sd.next', 'updated': '2023-07-18', 'hash': '0a083c24', 'url': 'https://github.com/vladmandic/automatic/tree/master'}                                                    
09:33:04-713156 INFO     Using data path: /home/user/automatic                                                                                                                                             
09:33:04-714117 DEBUG    Event loop: <_UnixSelectorEventLoop running=False closed=False debug=False>                                                                                                               
09:33:04-715067 DEBUG    Entering initialize                                                                                                                                                                       
09:33:04-716367 INFO     Available VAEs: /home/user/automatic/models/VAE 0                                                                                                                                 
09:33:04-720569 INFO     Available models: /home/user/automatic/models/Stable-diffusion 1                                                                                                                  
09:33:04-748620 DEBUG    Loading scripts                                                                                                                                                                           
09:33:06-522451 INFO     ControlNet v1.1.233                                                                                                                                                                       
ControlNet v1.1.233
ControlNet preprocessor location: /home/user/automatic/extensions-builtin/sd-webui-controlnet/annotator/downloads
09:33:06-683765 INFO     ControlNet v1.1.233                                                                                                                                                                       
ControlNet v1.1.233
09:33:07-375748 DEBUG    Scripts load: ['a1111-sd-webui-lycoris:0.577s', 'clip-interrogator-ext:0.052s', 'Lora:0.265s', 'sd-extension-system-info:0.092s', 'sd-webui-agent-scheduler:0.563s',                      
                         'sd-webui-controlnet:0.285s', 'stable-diffusion-webui-images-browser:0.228s', 'stable-diffusion-webui-rembg:0.348s', 'SwinIR:0.055s', 'ScuNET:0.057s']                                    
Scripts load: ['a1111-sd-webui-lycoris:0.577s', 'clip-interrogator-ext:0.052s', 'Lora:0.265s', 'sd-extension-system-info:0.092s', 'sd-webui-agent-scheduler:0.563s', 'sd-webui-controlnet:0.285s', 'stable-diffusion-webui-images-browser:0.228s', 'stable-diffusion-webui-rembg:0.348s', 'SwinIR:0.055s', 'ScuNET:0.057s']
09:33:07-429097 INFO     Loading UI theme: name=black-orange style=Auto                                                                                                                                            
09:33:07-430873 DEBUG    Creating UI                                                                                                                                                                               
09:33:07-457633 DEBUG    Extra networks: checkpoints items=1 subdirs=0                                                                                                                                             
09:33:07-658769 DEBUG    Reading: /home/user/automatic/ui-config.json len=0                                                                                                                                
09:33:08-319638 DEBUG    Script: 0.22s ui_tabs /home/user/automatic/extensions-builtin/stable-diffusion-webui-images-browser/scripts/image_browser.py                                                      
09:33:08-322389 DEBUG    Extensions list failed to load: /home/user/automatic/html/extensions.json                                                                                                         
Running on local URL:  http://0.0.0.0:7860

When I go on the web interface, everything seems OK. But when I try anything, I have this pop-up popping up on the top right:

Something went wrong
Expecting value: line 2 column 1 (char 1)

Capture d’écran du 2023-07-19 11-36-46

I have nothing more displayed on the console... I don't know how to solve the problem. I tried deleting the generated JSON file, but it recreated it and the problem continues.

I specify that a clone of this VM works without any problem with Easy-Diffusion and SD 2.1. I haven't tested automatic1111's git, because I'm trying to get the SDXL to work, but I can't get it to work with a basic installation, with the SD 1.5 offered for download when launching webui.sh...

Any help appreciated.

Version Platform Description

On a Proxmox 7.4-3 (2x AMD EPYC 7552 48-Core Processor, 512 GB RAM, 3x NVIDIA Tesla T4) Virtual Machine with : vCPU 8 core (mode host, AMD EPYC 7552 48-Core Processor) 64 GB RAM Passtrough PCI on 1x NVIDIA Tesla T4 Disk 64GB Fresh install Linux Ubuntu 22.04 (with the python3.10 embedded) NVIDIA drivers installed with :

sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt update
sudo apt install nvidia-driver-535

For the venv :

sudo apt install python3.10-venv

My browser on my workstation is Firefox dev 106 (already tested on Google Chrome).

Acknowledgements

vladmandic commented 1 year ago

using both --share and --listen at the same time should not be done. lets focus on default startup. you get error?

ValueError: When localhost is not accessible, a shareable link must be created. Please set share=True or check your proxy settings to allow access to localhost.

that means that app could not bind to a port (default is 7860). if port is busy, it would say so. this just says its not working. i don't know what is a proxmox or how is vm created, but it seems that vm has limited networking capabilities or its locked down so much from security perspective it doesn't allow required network bindings.

Rollbacke commented 1 year ago

OK, your post got me thinking.

Proxmox is an open-source hypervisor equivalent to VMware ESXi. It is a rather professional oriented "server" virtualization system. There is absolutely no limitation because it is a virtual machine under Promox. Port 7860 is free as this is a fresh install of ubuntu 22.04.

But ! On the other hand, being in a professional network, I had indeed the use of a proxy, which I had entered in the webui-user.sh file:

export http_proxy="http://proxy:3128/"
export https_proxy="http://proxy:3128/"
export HTTP_PROXY="http://proxy:3128/"
export HTTPS_PROXY="http://proxy:3128/"

The proxy being very permissive, and the localhost having no link with the proxy (no system passes the localhost through a proxy, it would be completely stupid), I told myself that the problem could not come from there.

While listening to the network (tcpdump), I spotted a repetitive stream that appeared to be blocked by the proxy. By analyzing the proxy logs, it therefore seems that the "localhost" wants to go through the proxy... (I replace my private IP and my fqdn) :

1689769716.441      0 my_private_ip TCP_MISS/503 3975 GET http://localhost.my_fqdn:7860/startup-events - HIER_DIRECT/127.0.0.1 text/html
1689769716.444      0 my_private_ip TCP_MISS/503 325 HEAD http://localhost.my_fqdn:7860/ - HIER_DIRECT/127.0.0.1 text/html
1689769716.949      0 my_private_ip TCP_MISS/503 325 HEAD http://localhost.my_fqdn:7860/ - HIER_DIRECT/127.0.0.1 text/html
1689769717.453      0 my_private_ip TCP_MISS/503 325 HEAD http://localhost.my_fqdn:7860/ - HIER_DIRECT/127.0.0.1 text/html
1689769717.957      0 my_private_ip TCP_MISS/503 325 HEAD http://localhost.my_fqdn:7860/ - HIER_DIRECT/127.0.0.1 text/html
1689769718.462      0 my_private_ip TCP_MISS/503 325 HEAD http://localhost.my_fqdn:7860/ - HIER_DIRECT/127.0.0.1 text/html
1689770110.009    256 my_private_ip TCP_TUNNEL/200 5232 CONNECT api.github.com:443 - HIER_DIRECT/140.82.121.6 -
1689770118.728     21 my_private_ip TCP_TUNNEL/200 5884 CONNECT fonts.googleapis.com:443 - HIER_DIRECT/216.58.214.170 -
1689770120.057      0 my_private_ip TCP_MISS/503 3939 GET http://127.0.0.1:7860/startup-events - HIER_DIRECT/127.0.0.1 text/html
1689770120.060      0 my_private_ip TCP_MISS/503 325 HEAD http://127.0.0.1:7860/ - HIER_DIRECT/127.0.0.1 text/html
1689770120.565      0 my_private_ip TCP_MISS/503 325 HEAD http://127.0.0.1:7860/ - HIER_DIRECT/127.0.0.1 text/html
1689770121.069      0 my_private_ip TCP_MISS/503 325 HEAD http://127.0.0.1:7860/ - HIER_DIRECT/127.0.0.1 text/html
1689770121.573      0 my_private_ip TCP_MISS/503 325 HEAD http://127.0.0.1:7860/ - HIER_DIRECT/127.0.0.1 text/html
1689770122.078      0 my_private_ip TCP_MISS/503 325 HEAD http://127.0.0.1:7860/ - HIER_DIRECT/127.0.0.1 text/html

Maybe there is a change to fix this?

Rollbacke commented 1 year ago

I forgot to specify, but by opening the ports 80/443 streams in my firewall (to avoid having to use a proxy for the python get) and unset the variables for the proxy, it works now.

vladmandic commented 1 year ago

those are connections created by gradio, not by app. i don't like it, but will have to trace it down and figure out how to monkey-patch gradio not to do those things.

Rollbacke commented 1 year ago

OK. So keep an eye on it :D (Thanks !)

vladmandic commented 1 year ago

following-up, fonts.googleapis.com access is fully optional and wrapped in try/except block. if there is no internet access, it will use default fonts set by os.

i don't know who is making connection to api.github.com (could be any number of packages, its not the app itself), but access seems to be optional as well as as there are no issues working fully offline.

so basically, i cant reproduce your original issues - it seems to happen when those connections are neither ok or rejected, only when connection is hanging as its not either fulfilled or rejected.

Rollbacke commented 1 year ago

Occasionally, if I have time, I'll try to find out which file is responsible to see if we can force a proxy exception for the localhost.

vladmandic commented 1 year ago

if you do find out, let me know.