ShmuelRonen / ComfyUI_wav2lip

A custom node for ComfyUI that allows you to perform lip-syncing on videos using the Wav2Lip model. It takes an input video and an audio file and generates a lip-synced output video.
53 stars 10 forks source link

[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired #28

Closed TheShadowNYC closed 1 week ago

TheShadowNYC commented 1 week ago
          Hello, saw this was closed, but after pulling update and trying reinstalling using instructions I'm still seeing error in trying to use this node. 

File "D:\06_Comfy\ComfyUI_windows_portable_nvidia_cu118_or_cpu\ComfyUI_windows_portable\python_embeded\lib\site-packages\torch\hub.py", line 622, in download_url_to_file u = urlopen(req) File "urllib\request.py", line 216, in urlopen File "urllib\request.py", line 519, in open File "urllib\request.py", line 536, in _open File "urllib\request.py", line 496, in _call_chain File "urllib\request.py", line 1391, in https_open File "urllib\request.py", line 1351, in do_open urllib.error.URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:997)>

Any suggestions appreciated.

Thank you.

_Originally posted by @TheShadowNYC in https://github.com/ShmuelRonen/ComfyUI_wav2lip/issues/27#issuecomment-2184066846_

ShmuelRonen commented 1 week ago

I have no answerer for you

TheShadowNYC commented 1 week ago

Hi Shmuel, ok, thank you for your time. If I find solution I'll drop it here for awareness.

TheShadowNYC commented 1 week ago

Hi Shmuel, wanted to follow up as someone helped identify that this issue was related to some localized network interference from anti-virus software. With that said, I was able to localize the models needed to run the node, however the code still attempts to download them. Is there a way to make a version that uses only localized models in the following folders?

ComfyUI_wav2lip-main/ ├── init.py ├── wav2lip.py ├── Wav2Lip/ │ ├── init.py │ ├── wav2lip_node.py │ └── checkpoints/ │ ├── wav2lip_gan.pth │ ├── lipsync_expert.pth │ ├── visual_quality_disc.pth │ └── face_detection/ │ └── detection/ │ └── sfd/ │ └── s3fd-619a316812.pth

TheShadowNYC commented 1 week ago

Silver made the models available here btw... https://huggingface.co/silveroxides/ComfyUI_wav2lip-models/tree/main

ShmuelRonen commented 1 week ago

The error you are seeing, [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:997), indicates that an SSL certificate being used to establish a secure connection has expired. This is commonly seen when making HTTPS requests and the certificate validation fails due to it being out of date.

Here are some potential solutions to resolve this issue:

Update Your System Certificates: Ensure that your system’s root certificates are up to date. On Windows, you might need to update the operating system or install the latest root certificate updates. For Linux or Mac, updating your OS or running a command to update certificates might help.

Manual Certificate Installation: If you are aware of the specific server or service causing the issue, you can manually download the updated certificate and install it on your system.

Use certifi Library: Python’s certifi library can be used to ensure you have the latest root certificates. You can install it using:

sh Copy code pip install certifi And then update your script to use these certificates:

python Copy code import ssl import certifi ssl_context = ssl.create_default_context(cafile=certifi.where()) response = urlopen(url, context=ssl_context) Disable SSL Verification (Not Recommended for Production): For testing purposes, you can disable SSL verification, though this is not secure and should not be used in a production environment.

python Copy code import ssl ssl_context = ssl._create_unverified_context() response = urlopen(url, context=ssl_context) Check Date and Time Settings: Ensure your system date and time settings are correct. Incorrect settings can sometimes cause certificate verification issues.

TheShadowNYC commented 1 week ago

thank you, I'll try this