This commit is contained in:
owenchen committed 2026-06-23 15:32:23 +08:00
1 parent 2c6475b2d5
commit 5fe7c6260e
4 files changed
+21 -6

No files matched your search

+11 -2
View File
@@ -22,10 +22,19 @@ namespace CloudBuilder.Topshelf.Python
if (!File.Exists(file)) return;
string init = File.ReadAllText(file, Encoding.UTF8);
File.AppendAllText("log.txt", "SoVITS:" + file + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "\r\n");
using (Py.GIL())
{
python.Exec(init);
try
{
python.Exec(init);
}
catch (Exception ex)
{
File.AppendAllText("log.txt", "SoVITS-Exec:" + ex.Message + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "\r\n");
}
File.AppendAllText("log.txt", "SoVITS-Exec:" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "\r\n");
}
}