Skip to content

Commit 8049761

Browse files
authored
Move chardet import into the win32 if case
1 parent 5784490 commit 8049761

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/aiida/transports/transport.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -503,6 +503,7 @@ def exec_command_wait(
503503
)
504504
# Return the decoded strings
505505
if sys.platform == 'win32':
506+
import chardet
506507
outenc = chardet.detect(stdout_bytes)['encoding']
507508
errenc = chardet.detect(stderr_bytes)['encoding']
508509
if outenc is None:

0 commit comments

Comments
 (0)