Skip to content

Commit 70ea7ec

Browse files
committed
Fix annotations for Python 3.8 and lower
1 parent a5414bf commit 70ea7ec

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

test/test_index.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
import re
1414
import shutil
1515
from stat import S_ISLNK, ST_MODE
16-
from subprocess import CompletedProcess, run
16+
import subprocess
1717
import tempfile
1818

1919
import ddt
@@ -93,14 +93,14 @@ class Wsl:
9393
class WslNoDistro:
9494
"""Running bash.exe tries to run bash on a WSL distribution, but none exists."""
9595

96-
process: CompletedProcess[bytes]
96+
process: "subprocess.CompletedProcess[bytes]"
9797
message: str
9898

9999
@dataclass
100100
class CheckError:
101101
"""Running bash.exe fails in an unexpected error or gives unexpected output."""
102102

103-
process: CompletedProcess[bytes]
103+
process: "subprocess.CompletedProcess[bytes]"
104104
message: str
105105

106106
@dataclass
@@ -133,7 +133,7 @@ def check(cls):
133133
# information on ways to check for WSL, see https://superuser.com/a/1749811.
134134
script = 'test -e /proc/sys/fs/binfmt_misc/WSLInterop; echo "$?"'
135135
command = ["bash.exe", "-c", script]
136-
process = run(command, capture_output=True)
136+
process = subprocess.run(command, capture_output=True)
137137
except FileNotFoundError:
138138
return cls.Absent()
139139
except OSError as error:

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy