🐛[bugfix] Main/Controller : 処理順を修正
This commit is contained in:
@@ -1663,8 +1663,8 @@ class Controller:
|
|||||||
self.run(200, self.run_mapping["initialization_progress"], progress)
|
self.run(200, self.run_mapping["initialization_progress"], progress)
|
||||||
|
|
||||||
def init(self, *args, **kwargs) -> None:
|
def init(self, *args, **kwargs) -> None:
|
||||||
printLog("Start Initialization")
|
|
||||||
removeLog()
|
removeLog()
|
||||||
|
printLog("Start Initialization")
|
||||||
|
|
||||||
printLog("Init Translation Engine Status")
|
printLog("Init Translation Engine Status")
|
||||||
for engine in config.SELECTABLE_TRANSLATION_ENGINE_LIST:
|
for engine in config.SELECTABLE_TRANSLATION_ENGINE_LIST:
|
||||||
|
|||||||
@@ -7,8 +7,6 @@ from queue import Queue
|
|||||||
from controller import Controller
|
from controller import Controller
|
||||||
from utils import printLog, printResponse, errorLogging, encodeBase64
|
from utils import printLog, printResponse, errorLogging, encodeBase64
|
||||||
|
|
||||||
controller = Controller()
|
|
||||||
|
|
||||||
run_mapping = {
|
run_mapping = {
|
||||||
"transcription_mic":"/run/transcription_send_mic_message",
|
"transcription_mic":"/run/transcription_send_mic_message",
|
||||||
"transcription_speaker":"/run/transcription_receive_speaker_message",
|
"transcription_speaker":"/run/transcription_receive_speaker_message",
|
||||||
@@ -41,11 +39,11 @@ run_mapping = {
|
|||||||
"initialization_complete":"/run/initialization_complete",
|
"initialization_complete":"/run/initialization_complete",
|
||||||
}
|
}
|
||||||
|
|
||||||
controller.setRunMapping(run_mapping)
|
|
||||||
|
|
||||||
def run(status:int, endpoint:str, result:Any) -> None:
|
def run(status:int, endpoint:str, result:Any) -> None:
|
||||||
printResponse(status, endpoint, result)
|
printResponse(status, endpoint, result)
|
||||||
|
|
||||||
|
controller = Controller()
|
||||||
|
controller.setRunMapping(run_mapping)
|
||||||
controller.setRun(run)
|
controller.setRun(run)
|
||||||
|
|
||||||
mapping = {
|
mapping = {
|
||||||
|
|||||||
Reference in New Issue
Block a user