File tree Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Original file line number Diff line number Diff line change 11from io import BufferedWriter , TextIOWrapper
22from logging import getLogger
33
4- from serial import SerialTimeoutException
54from rich .progress import Progress , TextColumn , BarColumn , TimeElapsedColumn
65from geocompy .communication import open_serial
76
@@ -92,7 +91,7 @@ def main_download(
9291 total = lines
9392 )
9493 break
95- except SerialTimeoutException :
94+ except TimeoutError :
9695 if started and autoclose :
9796 logger .info ("Download finished (timeout)" )
9897 print_success ("Download finished due to timeout" )
Original file line number Diff line number Diff line change 55from rich .live import Live
66from rich .table import Table , Column
77from rich .prompt import Confirm
8- from serial import SerialException
98from geocompy .data import Angle
109from geocompy .geo import GeoCom
1110from geocompy .geo .gcdata import Device
@@ -177,6 +176,6 @@ def main(
177176 "An exception occured while running the tests"
178177 )
179178
180- except (SerialException , ConnectionError ) as e :
179+ except (ConnectionRefusedError , ConnectionError ) as e :
181180 print_error (f"Connection was not successful ({ e } )" )
182181 logger .exception ("Connection was not successful" )
You can’t perform that action at this time.
0 commit comments