From 14a4a1ed99cba7f9aae1538057a5eeda6c778508 Mon Sep 17 00:00:00 2001 From: Sakamoto Shiina <68018796+ShiinaSakamoto@users.noreply.github.com> Date: Sat, 29 Nov 2025 15:58:52 +0900 Subject: [PATCH] [Update] Add an error notification that is when an invalid endpoint or message is received(mostly frontend side endpoint error handling bug). --- src-ui/logics/_useBackendErrorHandling.js | 3 +++ src-ui/views/app/_app_controllers/StartPythonController.jsx | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src-ui/logics/_useBackendErrorHandling.js b/src-ui/logics/_useBackendErrorHandling.js index eb8bcae0..307520ea 100644 --- a/src-ui/logics/_useBackendErrorHandling.js +++ b/src-ui/logics/_useBackendErrorHandling.js @@ -241,6 +241,9 @@ export const _useBackendErrorHandling = () => { default: console.error(`Invalid endpoint or message: ${endpoint}\nmessage: ${message}\nresult: ${JSON.stringify(result)}`); + showNotification_Error( + `An error occurred. Please contact the developers and restart VRCT. Error: Invalid endpoint or message: ${endpoint}\nmessage: ${message}\nresult: ${JSON.stringify(result)}`, { hide_duration: null } + ); return; } diff --git a/src-ui/views/app/_app_controllers/StartPythonController.jsx b/src-ui/views/app/_app_controllers/StartPythonController.jsx index 55824bc8..d2781abf 100644 --- a/src-ui/views/app/_app_controllers/StartPythonController.jsx +++ b/src-ui/views/app/_app_controllers/StartPythonController.jsx @@ -49,7 +49,8 @@ const useStartPython = () => { }); command.stderr.on("data", line => { showNotification_Error( - `An error occurred. Please restart VRCT or contact the developers. The last line:${JSON.stringify(line)}`, { hide_duration: null }); + `An error occurred. Please restart VRCT or contact the developers. The last line:${JSON.stringify(line)}`, { hide_duration: null } + ); console.error("stderr", line); }); const backend_subprocess = await command.spawn();