Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion build_scripts/windows/scripts/az
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env bash

AZ_INSTALLER=MSI "$(dirname "${BASH_SOURCE[0]}")/../python.exe" -IBm azure.cli "$@"
SCRIPT_DIR=$(dirname "${BASH_SOURCE[0]}")
export PYTHONPATH="$(dirname "$SCRIPT_DIR")"
AZ_INSTALLER=MSI "$SCRIPT_DIR/../python.exe" -IBm azure.cli "$@"
1 change: 1 addition & 0 deletions build_scripts/windows/scripts/az_msi.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
::

@IF EXIST "%~dp0\..\python.exe" (
SET PYTHONPATH=%~dp0\..;%PYTHONPATH%
SET AZ_INSTALLER=MSI
"%~dp0\..\python.exe" -IBm azure.cli %*
) ELSE (
Expand Down
1 change: 1 addition & 0 deletions build_scripts/windows/scripts/az_zip.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
::

@IF EXIST "%~dp0\..\python.exe" (
SET PYTHONPATH=%~dp0\..;%PYTHONPATH%
SET AZ_INSTALLER=ZIP
"%~dp0\..\python.exe" -IBm azure.cli %*
Copy link
Copy Markdown
Contributor

@bebound bebound Feb 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The root cause of the crash is Python 3.12.8 loads 3.12.x's module(C:\\Users\\xxx\\AppData\\Local\\Programs\\Python\\Python312\\Lib) when run pip.(#30594 (comment))

We have -I option when run az, but we don't have it in pip.

cmd = [sys.executable, '-m', 'pip'] + pip_exec_args + ['--disable-pip-version-check', '--no-cache-dir']

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this just an observation, or do you want me to change anything in my commit?

) ELSE (
Expand Down
Loading