Uplink Issue: Local issuer Certificate

Hi. Im trying to use uplink in Anvil
but im getting this error:

Connecting to wss://anvil.works/uplink
Traceback (most recent call last):
  File "XXXXXXXXX/main.py", line 49, in <module>
    anvil.server.connect("server_XXXXXXXXXXXXXXXXXXXXXX")
  File "XXXXXXXXXX.venv/lib/python3.12/site-packages/anvil/server.py", line 362, in connect
    _get_connection()
  File "XXXXXXXXXX/.venv/lib/python3.12/site-packages/anvil/server.py", line 344, in _get_connection
    raise e
  File "XXXXXXXXXX./.venv/lib/python3.12/site-packages/anvil/server.py", line 341, in _get_connection
    _connection.connect()
  File "XXXXXXXXXX./.venv/lib/python3.12/site-packages/ws4py/client/__init__.py", line 220, in connect
    self.sock.connect(self.bind_addr)
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/ssl.py", line 1352, in connect
    self._real_connect(addr, False)
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/ssl.py", line 1343, in _real_connect
    self.do_handshake()
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/ssl.py", line 1319, in do_handshake
    self._sslobj.do_handshake()
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1000)

This is the code im trying to connect

import anvil.server
anvil.server.connect("server_XXXXXXXXXXXXXXXXXXXXXXXX")
anvil.server.wait_forever()

some help would be greatly appreciated, thanks guys

What version of uplink? If its less than 5.0 then pip install anvil-uplink --upgrade

If that is not it, then you might need to run it with python 3.11 or less because of an ssl library incompatibility with 3.12

1 Like

That’s been fixed

2 Likes