We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 29f4f87 commit de48f84Copy full SHA for de48f84
tests/utils.py
@@ -1,6 +1,7 @@
1
import os
2
import platform
3
import subprocess
4
+import sys
5
from contextlib import contextmanager
6
from typing import Dict, Optional, Union, List
7
@@ -42,6 +43,11 @@ def run_command(
42
43
if env is None:
44
env = os.environ.copy()
45
46
+ # Special handling for 'dotenv' commands - use Python module directly
47
+ if isinstance(cmd, list) and cmd and cmd[0] == "dotenv":
48
+ # Replace 'dotenv' with 'python -m dotenv'
49
+ cmd = [sys.executable, "-m", "dotenv"] + cmd[1:]
50
+
51
# Convert string command to list for subprocess if needed
52
if isinstance(cmd, str):
53
if IS_WINDOWS:
0 commit comments