Closed mqtt-fan closed 8 months ago
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1000)
This indicates that the certificate is not regarded as valid by your local gradio client + the following errors show that the response is empty, which is why the array key check fails. Please check if the certificate used by gradio.live is valid if you open it in browser and if your network firewall/router/adblock filters gradio.live domains and let me know the results.
Hi @mashb1t
I'm sorry, I copied an old try instead of the script. Now I edited the issue. (I used this script: https://github.com/lllyasviel/Fooocus/issues/1293#issuecomment-1848712861)
Can you take a look at the script, why it says:
TypeError: argument of type 'NoneType' is not iterable
The fooocus logs are telling this:
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
So I thing the request from the python script must be wrong
The Fooocus interface has changed a bit since the other issue has been opened. Please find the current request example in the API definition in the Footer of Fooocus, fn_index: 32 or 33 (currently not certain).
Thanks for the hint, it is getting stranger and stranger.
If I used 33:
from gradio_client import Client
client = Client("https://7c3ae305b3b6380dfc.gradio.live/")
result = client.predict(
"Howdy!", # str in 'parameter_10' Textbox component
"Howdy!", # str in 'Negative Prompt' Textbox component
["Fooocus V2"], # List[str] in 'Selected Styles' Checkboxgroup component
"Speed", # str in 'Performance' Radio component
"704×1408 <span style="color: grey;"> ∣ 1:2</span>",
1, # int | float (numeric value between 1 and 32)
"Howdy!", # str in 'Seed' Textbox component
0, # int | float (numeric value between 0.0 and 30.0)
1, # int | float (numeric value between 1.0 and 30.0)
"juggernautXL_version6Rundiffusion.safetensors", # str (Option from: ['juggernautXL_version6Rundiffusion.safetensors', 'realism_engine_sdxl.safetensors'])
"None", # str (Option from: ['None', 'juggernautXL_version6Rundiffusion.safetensors', 'realism_engine_sdxl.safetensors'])
0.1, # int | float (numeric value between 0.1 and 1.0)
"None", # str (Option from: ['None'])
-2, # int | float (numeric value between -2 and 2)
"None", # str (Option from: ['None'])
-2, # int | float (numeric value between -2 and 2)
"None", # str (Option from: ['None'])
-2, # int | float (numeric value between -2 and 2)
"None", # str (Option from: ['None'])
-2, # int | float (numeric value between -2 and 2)
"None", # str (Option from: ['None'])
-2, # int | float (numeric value between -2 and 2)
True, # bool in 'Input Image' Checkbox component
"Howdy!", # str in 'parameter_85' Textbox component
"Disabled", # str in 'Upscale or Variation:' Radio component
"https://raw.githubusercontent.com/gradio-app/gradio/main/test/test_files/bus.png", # str (filepath or URL to image)
["Left"], # List[str] in 'Outpaint Direction' Checkboxgroup component
"https://raw.githubusercontent.com/gradio-app/gradio/main/test/test_files/bus.png", # str (filepath or URL to image)
"Howdy!", # str in 'Inpaint Additional Prompt' Textbox component
"https://raw.githubusercontent.com/gradio-app/gradio/main/test/test_files/bus.png", # str (filepath or URL to image)
"https://raw.githubusercontent.com/gradio-app/gradio/main/test/test_files/bus.png", # str (filepath or URL to image)
0, # int | float (numeric value between 0.0 and 1.0)
0, # int | float (numeric value between 0.0 and 2.0)
"ImagePrompt", # str in 'Type' Radio component
"https://raw.githubusercontent.com/gradio-app/gradio/main/test/test_files/bus.png", # str (filepath or URL to image)
0, # int | float (numeric value between 0.0 and 1.0)
0, # int | float (numeric value between 0.0 and 2.0)
"ImagePrompt", # str in 'Type' Radio component
"https://raw.githubusercontent.com/gradio-app/gradio/main/test/test_files/bus.png", # str (filepath or URL to image)
0, # int | float (numeric value between 0.0 and 1.0)
0, # int | float (numeric value between 0.0 and 2.0)
"ImagePrompt", # str in 'Type' Radio component
"https://raw.githubusercontent.com/gradio-app/gradio/main/test/test_files/bus.png", # str (filepath or URL to image)
0, # int | float (numeric value between 0.0 and 1.0)
0, # int | float (numeric value between 0.0 and 2.0)
"ImagePrompt", # str in 'Type' Radio component
fn_index=33
)
print(result)
I got:
Bob@MacBook-Pro-von-Bob Downloads % python3 gen.py
File "/Users/Bib/Downloads/gen.py", line 9
"704×1408 <span style="color: grey;"> ∣ 1:2</span>",
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: invalid syntax. Perhaps you forgot a comma?
after change it to
result = client.predict(
"Howdy!", # str in 'parameter_10' Textbox component
"Howdy!", # str in 'Negative Prompt' Textbox component
["Fooocus V2"], # List[str] in 'Selected Styles' Checkboxgroup component
"Speed", # str in 'Performance' Radio component
"704×1408", ...
I got the error:
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1000)
But the url works fine in my browser and the is no issue at all
Looks like a issue with gradio and colab. Maybe someone can take a deeper look into this?
Can maybe someone reproduce to check if it is not an issue on my side?
Gradio v3.9 isn't working properly. It's throwing websocket 1006 error in Windows. Fooocus could try updating Gradio to latest v4.
Just an addition: Fooocus isn't using gradio 3.9 but 3.41.2. Upgrading to 4.x would be a major effort, which is not planned in the near future as far as i know.
Thanks for response. I will try spinning it in Ubuntu, sometime later and check if it fixes the issue or not.
@sumeetweb what's the result of your testing?
Closing as stale. One more hint: disable all VPNs before using Fooocus might help.
Hi all,
I'm tried to bulk create several images via the python gradio client. Currently I'm running Fooocus on google colab using this notebook (https://colab.research.google.com/github/lllyasviel/Fooocus/blob/main/fooocus_colab.ipynb)
Now I want create a image via a prompt sent by gradio client from my Mac.
I used the example found in the "Issues": gen.py:
Describe the problem I still got this error:
TypeError: argument of type 'NoneType' is not iterable
Python Package List on Mac:pip3 freeze:
Full Console Log
Can someone send me the correct call to generate a picture with positive and negative prompt?