1
0
Эх сурвалжийг харах

fix example for Python 3.8

Rodja Trappe 1 жил өмнө
parent
commit
c9639126d1

+ 2 - 1
examples/websockets/main.py

@@ -5,13 +5,14 @@ NOTE: NiceGUI already handles all the communication for you so you don't need to
 This example is only for advanced use cases where you want to allow other, non-NiceGUI clients to connect to your server.
 """
 import asyncio
+from typing import Set
 
 import websockets
 from websockets.server import WebSocketServerProtocol
 
 from nicegui import app, ui
 
-CONNECTIONS: set[WebSocketServerProtocol] = set()
+CONNECTIONS: Set[WebSocketServerProtocol] = set()
 
 ui.label('Websockets demo').classes('text-2xl')
 ui.label('Run this in the console to connect:')