From 5889416511f15896bdce47b53a49a720ea9c25b3 Mon Sep 17 00:00:00 2001 From: Daniel McKnight <34697904+NeonDaniel@users.noreply.github.com> Date: Tue, 11 Feb 2025 15:26:37 -0800 Subject: [PATCH] Deprecate `PIDLock` usage and update Dockerfile to resolve warnings (#206) # Description Deprecate PIDLock initialization Resolve Dockerfile warnings # Issues Closes #161 # Other Notes --- Dockerfile | 10 +++++----- neon_speech/__main__.py | 3 +-- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index 8770500..42a5afb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,11 +1,11 @@ -FROM python:3.10-slim as base +FROM python:3.10-slim AS base LABEL vendor=neon.ai \ ai.neon.name="neon-speech" -ENV OVOS_CONFIG_BASE_FOLDER neon -ENV OVOS_CONFIG_FILENAME neon.yaml -ENV XDG_CONFIG_HOME /config +ENV OVOS_CONFIG_BASE_FOLDER=neon +ENV OVOS_CONFIG_FILENAME=neon.yaml +ENV XDG_CONFIG_HOME=/config RUN apt-get update && \ apt-get install -y \ @@ -48,5 +48,5 @@ RUN neon-speech install-dependencies CMD ["/root/run.sh"] -FROM base as default_model +FROM base AS default_model RUN neon-speech init-plugin \ No newline at end of file diff --git a/neon_speech/__main__.py b/neon_speech/__main__.py index 3da9282..72e213c 100644 --- a/neon_speech/__main__.py +++ b/neon_speech/__main__.py @@ -30,7 +30,7 @@ from neon_utils.log_utils import init_log from neon_utils.process_utils import start_malloc, snapshot_malloc, print_malloc from ovos_utils.log import LOG -from ovos_utils.process_utils import PIDLock, reset_sigint_handler +from ovos_utils.process_utils import reset_sigint_handler from neon_speech.service import NeonSpeechClient @@ -42,7 +42,6 @@ def main(*args, **kwargs): kwargs["speech_config"] = kwargs.pop("config") reset_sigint_handler() - PIDLock("voice") malloc_running = start_malloc(stack_depth=4) service = NeonSpeechClient(*args, **kwargs) service.start()