Fixed "SocketException: Failed to create server socket stdout.sock"
This commit is contained in:
parent
669f6301f8
commit
12716dec8e
|
|
@ -177,6 +177,9 @@ Future<String?> runPythonApp() async {
|
|||
socketAddr = "$tcpAddr:${outSocketServer.port}";
|
||||
} else {
|
||||
socketAddr = "stdout.sock";
|
||||
if (await File(socketAddr).exists()) {
|
||||
await File(socketAddr).delete();
|
||||
}
|
||||
outSocketServer = await ServerSocket.bind(
|
||||
InternetAddress(socketAddr, type: InternetAddressType.unix), 0);
|
||||
debugPrint('Python output Socket Server is listening on $socketAddr');
|
||||
|
|
|
|||
Loading…
Reference in New Issue