Skip to content

Conversation

@alex-feel
Copy link
Owner

Replace caret (^) escaping approach with shell=True and double-quoted URLs for Windows CMD compatibility.

The previous escape_for_cmd() approach failed because subprocess.run() with list arguments uses subprocess.list2cmdline() which follows MSVC quoting rules, not CMD escaping rules. When calling .CMD batch files, Windows automatically invokes cmd.exe /c, causing & characters to be interpreted as command separators despite caret escaping.

Using shell=True with double-quoted URLs ensures & characters are protected from CMD interpretation, as documented in Python's subprocess documentation for batch files with special characters.

Replace caret (^) escaping approach with shell=True and double-quoted URLs for Windows CMD compatibility.

The previous escape_for_cmd() approach failed because subprocess.run() with list arguments uses subprocess.list2cmdline() which follows MSVC quoting rules, not CMD escaping rules. When calling .CMD batch files, Windows automatically invokes cmd.exe /c, causing & characters to be interpreted as command separators despite caret escaping.

Using shell=True with double-quoted URLs ensures & characters are protected from CMD interpretation, as documented in Python's subprocess documentation for batch files with special characters.
@github-actions
Copy link

github-actions bot commented Jan 7, 2026

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  scripts
  setup_environment.py
Project Total  

This report was generated by python-coverage-comment-action

@alex-feel alex-feel merged commit 8ef1502 into main Jan 7, 2026
12 checks passed
@alex-feel alex-feel deleted the alex-feel-dev branch January 7, 2026 19:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants