agoulddesign / krita-bg-remove-bria

A simple plugin for Krita that automatically removes the background of an image using BriaAI's API in seconds
MIT License
3 stars 0 forks source link

Error SSL certificate error #3

Open Mojas84 opened 1 week ago

Mojas84 commented 1 week ago

Hi please i try it Krita-BG-Remove-Bria but after setings api key and click remove write only Error: SSL cerificate verification failed. You may need update cerificate.

agoulddesign commented 6 days ago

Hello, what version of the plugin are you using, and what operating system?

Mojas84 commented 5 days ago

Hi. Latest 1.21 . Have Win11 24H2 august update....

agoulddesign commented 5 days ago

I just tested on Win11 32H2 and it worked fine. Can you make sure you don't have an antivirus or firewall blocking traffic to/from Krita?

Here is a ping test to see if it can reach the server. Go to Tools -> Scripts -> Scripter and paste this:

import socket
import time

def simple_ping(host, count=4):
    print(f"Pinging {host}...")
    for i in range(count):
        try:
            start_time = time.time()
            # Create a socket object
            sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
            # Set a timeout for the connection attempt
            sock.settimeout(2)
            # Attempt to connect
            result = sock.connect_ex((host, 80))
            end_time = time.time()

            if result == 0:
                print(f"Ping successful: {host} - Time: {(end_time - start_time)*1000:.2f}ms")
            else:
                print(f"Ping failed: {host} - Host is not responding")

            # Close the socket
            sock.close()
        except socket.gaierror:
            print(f"Ping error: {host} - Hostname could not be resolved")
        except socket.error:
            print(f"Ping error: {host} - Couldn't connect to server")

        # Wait a second before the next ping
        time.sleep(1)

# Example usage
simple_ping('engine.prod.bria-api.com')
Mojas84 commented 4 days ago

I just tested on Win11 32H2 and it worked fine. Can you make sure you don't have an antivirus or firewall blocking traffic to/from Krita?

Here is a ping test to see if it can reach the server. Go to Tools -> Scripts -> Scripter and paste this:

import socket
import time

def simple_ping(host, count=4):
    print(f"Pinging {host}...")
    for i in range(count):
        try:
            start_time = time.time()
            # Create a socket object
            sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
            # Set a timeout for the connection attempt
            sock.settimeout(2)
            # Attempt to connect
            result = sock.connect_ex((host, 80))
            end_time = time.time()

            if result == 0:
                print(f"Ping successful: {host} - Time: {(end_time - start_time)*1000:.2f}ms")
            else:
                print(f"Ping failed: {host} - Host is not responding")

            # Close the socket
            sock.close()
        except socket.gaierror:
            print(f"Ping error: {host} - Hostname could not be resolved")
        except socket.error:
            print(f"Ping error: {host} - Couldn't connect to server")

        # Wait a second before the next ping
        time.sleep(1)

# Example usage
simple_ping('engine.prod.bria-api.com')

==== Warning: Script not saved! ==== Pinging engine.prod.bria-api.com... Ping successful: engine.prod.bria-api.com - Time: 132.05ms Ping successful: engine.prod.bria-api.com - Time: 30.69ms Ping successful: engine.prod.bria-api.com - Time: 18.80ms Ping successful: engine.prod.bria-api.com - Time: 21.57ms ==== Warning: Script not saved! ====

agoulddesign commented 3 days ago

Are you using the most recent version of Krita?