Compare commits

..

No commits in common. "af6e0f69be51effb881a3dafb858bf3dde1ca0be" and "4fce750223cb46c266a756aac4e910082f528e41" have entirely different histories.

2 changed files with 7 additions and 10 deletions

View File

@ -227,11 +227,8 @@ class Window(QMainWindow, Ui_MainWindow):
self.move_source_model: Optional[PlaylistProxyModel] = None self.move_source_model: Optional[PlaylistProxyModel] = None
self.audacity_file_path: Optional[str] = None self.audacity_file_path: Optional[str] = None
# Initialise Audacity access # Initialise Audacity access
try: self.audacity_client = pipeclient.PipeClient()
self.audacity_client = pipeclient.PipeClient() log.info(f"{hex(id(self.audacity_client))=}")
log.info(f"{hex(id(self.audacity_client))=}")
except RuntimeError as e:
log.error(f"Unable to initialise Audacity: {str(e)}")
if Config.CARTS_HIDE: if Config.CARTS_HIDE:
self.cartsWidget.hide() self.cartsWidget.hide()
@ -1493,7 +1490,7 @@ class Window(QMainWindow, Ui_MainWindow):
tab = self.active_tab() tab = self.active_tab()
if tab: if tab:
QTimer.singleShot(300, tab.resizeRowsToContents) tab.resizeRowsToContents()
def tick_10ms(self) -> None: def tick_10ms(self) -> None:
""" """

View File

@ -81,7 +81,7 @@ import argparse
if sys.version_info[0] < 3: if sys.version_info[0] < 3:
raise RuntimeError('PipeClient Error: Python 3.x required') sys.exit('PipeClient Error: Python 3.x required')
# Platform specific constants # Platform specific constants
if sys.platform == 'win32': if sys.platform == 'win32':
@ -156,7 +156,7 @@ class PipeClient():
# Allow a little time for connection to be made. # Allow a little time for connection to be made.
time.sleep(0.1) time.sleep(0.1)
if not self._write_pipe: if not self._write_pipe:
raise RuntimeError('PipeClientError: Write pipe cannot be opened.') sys.exit('PipeClientError: Write pipe cannot be opened.')
def _write_pipe_open(self) -> None: def _write_pipe_open(self) -> None:
"""Open _write_pipe.""" """Open _write_pipe."""
@ -187,7 +187,7 @@ class PipeClient():
self._write_pipe.write(command + EOL) self._write_pipe.write(command + EOL)
# Check that read pipe is alive # Check that read pipe is alive
if PipeClient.reader_pipe_broken.is_set(): if PipeClient.reader_pipe_broken.is_set():
raise RuntimeError('PipeClient: Read-pipe error.') sys.exit('PipeClient: Read-pipe error.')
try: try:
self._write_pipe.flush() self._write_pipe.flush()
if self.timer: if self.timer:
@ -196,7 +196,7 @@ class PipeClient():
PipeClient.reply_ready.clear() PipeClient.reply_ready.clear()
except IOError as err: except IOError as err:
if err.errno == errno.EPIPE: if err.errno == errno.EPIPE:
raise RuntimeError('PipeClient: Write-pipe error.') sys.exit('PipeClient: Write-pipe error.')
else: else:
raise raise