Skip to content

Commit 44f4805

Browse files
authored
Only warn if scratch cloud is used
Signed-off-by: TheCommCraft <79996518+TheCommCraft@users.noreply.github.com>
1 parent 0efb507 commit 44f4805

File tree

1 file changed

+14
-16
lines changed

1 file changed

+14
-16
lines changed

scratchattach/cloud/_base.py

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -335,22 +335,20 @@ def _handshake(self):
335335
self._send_packet(packet)
336336

337337
def connect(self):
338-
try:
339-
self.websocket = websocket.WebSocket(sslopt={"cert_reqs": ssl.CERT_NONE})
340-
self.websocket.connect(
341-
self.cloud_host,
342-
cookie=self.cookie,
343-
origin=self.origin,
344-
enable_multithread=True,
345-
timeout=self.ws_timeout,
346-
header=self.header
347-
)
348-
self._handshake()
349-
self.active_connection = True
350-
if self.print_connect_message:
351-
print("Connected to cloud server ", self.cloud_host)
352-
except WebSocketBadStatusException as e:
353-
raise WebSocketBadStatusException(f"Error: Scratch's Cloud system may be down. Please try again later.") from e
338+
self.websocket = websocket.WebSocket(sslopt={"cert_reqs": ssl.CERT_NONE})
339+
self.websocket.connect(
340+
self.cloud_host,
341+
cookie=self.cookie,
342+
origin=self.origin,
343+
enable_multithread=True,
344+
timeout=self.ws_timeout,
345+
header=self.header
346+
)
347+
self._handshake()
348+
self.active_connection = True
349+
if self.print_connect_message:
350+
print("Connected to cloud server ", self.cloud_host)
351+
354352
def disconnect(self):
355353
self.active_connection = False
356354
if self.recorder is not None:

0 commit comments

Comments
 (0)