From 4bf2282f18d79e47aee46451ab384f52f328875b Mon Sep 17 00:00:00 2001 From: Dmytro Bogovych Date: Tue, 22 Aug 2023 15:23:09 +0300 Subject: [PATCH] - +1 minor fix --- src/agent_gsm.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/agent_gsm.py b/src/agent_gsm.py index 3ff2097..7e7665e 100644 --- a/src/agent_gsm.py +++ b/src/agent_gsm.py @@ -114,7 +114,7 @@ def upload_results(): # Path to audio path_audio = t[1] - print(f'Found {path_report.name} and {path_audio.name} files.') + utils.log(f'Found {path_report.name} and {path_audio.name} files.') try: with open(path_report, 'rt') as f: report = json.loads(f.read()) @@ -127,16 +127,16 @@ def upload_results(): utils.log(f'Report {upload_id} is uploaded ok.') # Rename files to make sync audio filename with reported ones - path_report_fixed = CACHE.dir / f'{upload_id}.json' - path_report = path_report.rename(path_report_fixed) + # path_report_fixed = CACHE.dir / f'{upload_id}.json' + # path_report = path_report.rename(path_report_fixed) - path_audio_fixed = CACHE.dir / f'{upload_id}.wav' - path_audio = path_audio.rename(path_audio_fixed) - utils.log(f'Uploading {path_report.name} and {path_audio.name} files...') + # path_audio_fixed = CACHE.dir / f'{upload_id}.wav' + # path_audio = path_audio.rename(path_audio_fixed) + utils.log(f'Uploading {path_audio.name} file...') # Upload recorded audio upload_result = BackendServer.upload_audio(upload_id, path_audio) if upload_result: - utils.log('Recorded audio {upload_id}.wav is uploaded ok.') + utils.log(' Recorded audio {upload_id}.wav is uploaded ok.') os.remove(path_report) os.remove(path_audio) else: