1
0
mirror of https://github.com/esphome/esphome.git synced 2025-09-21 04:32:23 +01:00

Optimize subprocess performance with close_fds=False

This commit is contained in:
J. Nick Koston
2025-08-08 16:18:04 -05:00
parent ff9ddb9d68
commit 3ded96bb26
12 changed files with 40 additions and 13 deletions

View File

@@ -211,7 +211,7 @@ def _decode_pc(config, addr):
return
command = [idedata.addr2line_path, "-pfiaC", "-e", idedata.firmware_elf_path, addr]
try:
translation = subprocess.check_output(command).decode().strip()
translation = subprocess.check_output(command, close_fds=False).decode().strip()
except Exception: # pylint: disable=broad-except
_LOGGER.debug("Caught exception for command %s", command, exc_info=1)
return