Compare commits

..

6 Commits

Author SHA1 Message Date
Priya Gupta
8bbb5413e0 Update build-python-packages.yml (#279) 2024-06-09 23:03:19 -05:00
Matthieu Darbois
c990e6da95 chore: update action versions (#267)
This removes Node.js 16 deprecation warnings
2024-05-22 08:08:47 -05:00
HarithaVattikuti
521be20d1e Updated arm64 versions (#273) 2024-05-10 12:16:17 -05:00
github-actions[bot]
064829bd03 Update versions-manifest (#272)
Co-authored-by: Service account <no-reply@microsoft.com>
2024-05-09 21:56:46 -05:00
github-actions[bot]
b77a7dee85 Update versions-manifest (#270)
Co-authored-by: Service account <no-reply@microsoft.com>
2024-05-09 10:10:04 -05:00
Matthieu Darbois
37e7166250 fix: always reinstall pip (#271)
* fix: always reinstall pip

If the default pip version is also the latest one,
then the `pip` executable will be missing as the default pip
is installed only as `pip3`/`pip3.x`.

In order to always provide a `pip` executable, always reinstall pip.

* chore(ci): change default version to 3.12.3

Default to the latest stable version.
2024-05-09 08:58:58 -05:00
7 changed files with 127 additions and 43 deletions

View File

@@ -1,11 +1,11 @@
name: Build Python package
run-name: Generate Python ${{ inputs.VERSION || '3.11.0' }}
run-name: Generate Python ${{ inputs.VERSION || '3.12.3' }}
on:
workflow_dispatch:
inputs:
VERSION:
description: 'Python version to build and upload'
default: '3.11.0'
default: '3.12.3'
required: true
PUBLISH_RELEASES:
description: 'Whether to publish releases'
@@ -25,7 +25,7 @@ on:
- 'main'
env:
VERSION: ${{ inputs.VERSION || '3.11.0' }}
VERSION: ${{ inputs.VERSION || '3.12.3' }}
defaults:
run:
shell: pwsh
@@ -67,11 +67,11 @@ jobs:
include: ${{ fromJson(needs.generate_matrix.outputs.matrix) }}
runs-on: ${{ matrix.os }}
env:
ARTIFACT_NAME: python-${{ inputs.VERSION || '3.11.0' }}-${{ matrix.platform }}-${{ matrix.arch }}
ARTIFACT_NAME: python-${{ inputs.VERSION || '3.12.3' }}-${{ matrix.platform }}-${{ matrix.arch }}
steps:
- name: Check out repository code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
@@ -81,10 +81,11 @@ jobs:
-Platform ${{ matrix.platform }} -Architecture ${{ matrix.arch }}
- name: Publish artifact
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: ${{ env.ARTIFACT_NAME }}
path: ${{ runner.temp }}/artifact
if-no-files-found: error
test_python:
needs: [generate_matrix, build_python]
@@ -94,11 +95,11 @@ jobs:
include: ${{ fromJson(needs.generate_matrix.outputs.matrix) }}
runs-on: ${{ matrix.os }}
env:
ARTIFACT_NAME: python-${{ inputs.VERSION || '3.11.0' }}-${{ matrix.platform }}-${{ matrix.arch }}
ARTIFACT_NAME: python-${{ inputs.VERSION || '3.12.3' }}-${{ matrix.platform }}-${{ matrix.arch }}
steps:
- name: Check out repository code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true
@@ -111,9 +112,10 @@ jobs:
run: if [ -d /Library/Frameworks/Python.framework ]; then sudo rm -rf /Library/Frameworks/Python.framework; fi
- name: Download artifact
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
path: ${{ runner.temp }}
name: ${{ env.ARTIFACT_NAME }}
path: ${{ runner.temp }}/${{ env.ARTIFACT_NAME }}
- name: Extract files
run: |
@@ -138,7 +140,7 @@ jobs:
working-directory: ${{ runner.temp }}/${{ env.ARTIFACT_NAME }}
- name: Setup Python ${{ env.VERSION }}
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ env.VERSION }}
architecture: ${{ matrix.arch }}
@@ -156,7 +158,6 @@ jobs:
- name: Run tests
run: |
Install-Module Pester -Force -Scope CurrentUser
Import-Module Pester
$pesterContainer = New-PesterContainer -Path './python-tests.ps1' -Data @{
Version="${{ env.VERSION }}";
@@ -176,7 +177,10 @@ jobs:
needs: test_python
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v4
with:
pattern: python-*
merge-multiple: true
- name: Publish Release ${{ env.VERSION }}
id: create_release
@@ -202,7 +206,7 @@ jobs:
}
- name: Upload release assets
uses: actions/github-script@v6
uses: actions/github-script@v7
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
@@ -226,7 +230,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Trigger "Create Pull Request" workflow
uses: actions/github-script@v6
uses: actions/github-script@v7
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |

View File

@@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true

View File

@@ -15,10 +15,10 @@ jobs:
fail-fast: false
matrix:
os: [macos-latest, windows-latest, ubuntu-20.04, ubuntu-22.04]
python: [3.9.12, 3.10.8, 3.11.8]
python: [3.9.13, 3.10.11, 3.11.8]
steps:
- name: setup-python ${{ matrix.python }}
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

View File

@@ -71,7 +71,7 @@ chmod +x ../python $PYTHON_MAJOR $PYTHON_MAJOR_DOT_MINOR $PYTHON_MAJOR_MINOR pyt
echo "Upgrading pip..."
export PIP_ROOT_USER_ACTION=ignore
./python -m ensurepip
./python -m pip install --upgrade pip --disable-pip-version-check --no-warn-script-location
./python -m pip install --upgrade --force-reinstall pip --disable-pip-version-check --no-warn-script-location
echo "Install OpenSSL certificates"
sh -e "${PYTHON_APPLICATION_PATH}/Install Certificates.command"

View File

@@ -51,7 +51,7 @@ chmod +x ../python $PYTHON_MAJOR $PYTHON_MAJOR_DOT_MINOR $PYTHON_MAJORMINOR pyth
echo "Upgrading pip..."
export PIP_ROOT_USER_ACTION=ignore
./python -m ensurepip
./python -m pip install --upgrade pip --disable-pip-version-check --no-warn-script-location
./python -m pip install --upgrade --force-reinstall pip --disable-pip-version-check --no-warn-script-location
echo "Create complete file"
touch $PYTHON_TOOLCACHE_VERSION_PATH/x64.complete

View File

@@ -135,7 +135,7 @@ if ($MajorVersion -ne "2") {
Write-Host "Install and upgrade Pip"
$Env:PIP_ROOT_USER_ACTION = "ignore"
$PythonExePath = Join-Path -Path $PythonArchPath -ChildPath "python.exe"
cmd.exe /c "$PythonExePath -m ensurepip && $PythonExePath -m pip install --upgrade pip --no-warn-script-location"
cmd.exe /c "$PythonExePath -m ensurepip && $PythonExePath -m pip install --upgrade --force-reinstall pip --no-warn-script-location"
if ($LASTEXITCODE -ne 0) {
Throw "Error happened during pip installation / upgrade"
}

View File

@@ -1,4 +1,56 @@
[
{
"version": "3.13.0-beta.1",
"stable": false,
"release_url": "https://github.com/actions/python-versions/releases/tag/3.13.0-beta.1-9019422448",
"files": [
{
"filename": "python-3.13.0-beta.1-darwin-arm64.tar.gz",
"arch": "arm64",
"platform": "darwin",
"download_url": "https://github.com/actions/python-versions/releases/download/3.13.0-beta.1-9019422448/python-3.13.0-beta.1-darwin-arm64.tar.gz"
},
{
"filename": "python-3.13.0-beta.1-darwin-x64.tar.gz",
"arch": "x64",
"platform": "darwin",
"download_url": "https://github.com/actions/python-versions/releases/download/3.13.0-beta.1-9019422448/python-3.13.0-beta.1-darwin-x64.tar.gz"
},
{
"filename": "python-3.13.0-beta.1-linux-20.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "20.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.13.0-beta.1-9019422448/python-3.13.0-beta.1-linux-20.04-x64.tar.gz"
},
{
"filename": "python-3.13.0-beta.1-linux-22.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "22.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.13.0-beta.1-9019422448/python-3.13.0-beta.1-linux-22.04-x64.tar.gz"
},
{
"filename": "python-3.13.0-beta.1-linux-24.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "24.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.13.0-beta.1-9019422448/python-3.13.0-beta.1-linux-24.04-x64.tar.gz"
},
{
"filename": "python-3.13.0-beta.1-win32-x64.zip",
"arch": "x64",
"platform": "win32",
"download_url": "https://github.com/actions/python-versions/releases/download/3.13.0-beta.1-9019422448/python-3.13.0-beta.1-win32-x64.zip"
},
{
"filename": "python-3.13.0-beta.1-win32-x86.zip",
"arch": "x86",
"platform": "win32",
"download_url": "https://github.com/actions/python-versions/releases/download/3.13.0-beta.1-9019422448/python-3.13.0-beta.1-win32-x86.zip"
}
]
},
{
"version": "3.13.0-alpha.6",
"stable": false,
@@ -272,45 +324,52 @@
{
"version": "3.12.3",
"stable": true,
"release_url": "https://github.com/actions/python-versions/releases/tag/3.12.3-8625548520",
"release_url": "https://github.com/actions/python-versions/releases/tag/3.12.3-9019007027",
"files": [
{
"filename": "python-3.12.3-darwin-arm64.tar.gz",
"arch": "arm64",
"platform": "darwin",
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-8625548520/python-3.12.3-darwin-arm64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-9019007027/python-3.12.3-darwin-arm64.tar.gz"
},
{
"filename": "python-3.12.3-darwin-x64.tar.gz",
"arch": "x64",
"platform": "darwin",
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-8625548520/python-3.12.3-darwin-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-9019007027/python-3.12.3-darwin-x64.tar.gz"
},
{
"filename": "python-3.12.3-linux-20.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "20.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-8625548520/python-3.12.3-linux-20.04-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-9019007027/python-3.12.3-linux-20.04-x64.tar.gz"
},
{
"filename": "python-3.12.3-linux-22.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "22.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-8625548520/python-3.12.3-linux-22.04-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-9019007027/python-3.12.3-linux-22.04-x64.tar.gz"
},
{
"filename": "python-3.12.3-linux-24.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "24.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-9019007027/python-3.12.3-linux-24.04-x64.tar.gz"
},
{
"filename": "python-3.12.3-win32-x64.zip",
"arch": "x64",
"platform": "win32",
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-8625548520/python-3.12.3-win32-x64.zip"
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-9019007027/python-3.12.3-win32-x64.zip"
},
{
"filename": "python-3.12.3-win32-x86.zip",
"arch": "x86",
"platform": "win32",
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-8625548520/python-3.12.3-win32-x86.zip"
"download_url": "https://github.com/actions/python-versions/releases/download/3.12.3-9019007027/python-3.12.3-win32-x86.zip"
}
]
},
@@ -1088,45 +1147,52 @@
{
"version": "3.11.9",
"stable": true,
"release_url": "https://github.com/actions/python-versions/releases/tag/3.11.9-8525206794",
"release_url": "https://github.com/actions/python-versions/releases/tag/3.11.9-9018502536",
"files": [
{
"filename": "python-3.11.9-darwin-arm64.tar.gz",
"arch": "arm64",
"platform": "darwin",
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-8525206794/python-3.11.9-darwin-arm64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-9018502536/python-3.11.9-darwin-arm64.tar.gz"
},
{
"filename": "python-3.11.9-darwin-x64.tar.gz",
"arch": "x64",
"platform": "darwin",
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-8525206794/python-3.11.9-darwin-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-9018502536/python-3.11.9-darwin-x64.tar.gz"
},
{
"filename": "python-3.11.9-linux-20.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "20.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-8525206794/python-3.11.9-linux-20.04-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-9018502536/python-3.11.9-linux-20.04-x64.tar.gz"
},
{
"filename": "python-3.11.9-linux-22.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "22.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-8525206794/python-3.11.9-linux-22.04-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-9018502536/python-3.11.9-linux-22.04-x64.tar.gz"
},
{
"filename": "python-3.11.9-linux-24.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "24.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-9018502536/python-3.11.9-linux-24.04-x64.tar.gz"
},
{
"filename": "python-3.11.9-win32-x64.zip",
"arch": "x64",
"platform": "win32",
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-8525206794/python-3.11.9-win32-x64.zip"
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-9018502536/python-3.11.9-win32-x64.zip"
},
{
"filename": "python-3.11.9-win32-x86.zip",
"arch": "x86",
"platform": "win32",
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-8525206794/python-3.11.9-win32-x86.zip"
"download_url": "https://github.com/actions/python-versions/releases/download/3.11.9-9018502536/python-3.11.9-win32-x86.zip"
}
]
},
@@ -2136,27 +2202,34 @@
{
"version": "3.10.14",
"stable": true,
"release_url": "https://github.com/actions/python-versions/releases/tag/3.10.14-8361245787",
"release_url": "https://github.com/actions/python-versions/releases/tag/3.10.14-9004012336",
"files": [
{
"filename": "python-3.10.14-darwin-x64.tar.gz",
"arch": "x64",
"platform": "darwin",
"download_url": "https://github.com/actions/python-versions/releases/download/3.10.14-8361245787/python-3.10.14-darwin-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.10.14-9004012336/python-3.10.14-darwin-x64.tar.gz"
},
{
"filename": "python-3.10.14-linux-20.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "20.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.10.14-8361245787/python-3.10.14-linux-20.04-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.10.14-9004012336/python-3.10.14-linux-20.04-x64.tar.gz"
},
{
"filename": "python-3.10.14-linux-22.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "22.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.10.14-8361245787/python-3.10.14-linux-22.04-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.10.14-9004012336/python-3.10.14-linux-22.04-x64.tar.gz"
},
{
"filename": "python-3.10.14-linux-24.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "24.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.10.14-9004012336/python-3.10.14-linux-24.04-x64.tar.gz"
}
]
},
@@ -3317,27 +3390,34 @@
{
"version": "3.9.19",
"stable": true,
"release_url": "https://github.com/actions/python-versions/releases/tag/3.9.19-8362510609",
"release_url": "https://github.com/actions/python-versions/releases/tag/3.9.19-9003651947",
"files": [
{
"filename": "python-3.9.19-darwin-x64.tar.gz",
"arch": "x64",
"platform": "darwin",
"download_url": "https://github.com/actions/python-versions/releases/download/3.9.19-8362510609/python-3.9.19-darwin-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.9.19-9003651947/python-3.9.19-darwin-x64.tar.gz"
},
{
"filename": "python-3.9.19-linux-20.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "20.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.9.19-8362510609/python-3.9.19-linux-20.04-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.9.19-9003651947/python-3.9.19-linux-20.04-x64.tar.gz"
},
{
"filename": "python-3.9.19-linux-22.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "22.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.9.19-8362510609/python-3.9.19-linux-22.04-x64.tar.gz"
"download_url": "https://github.com/actions/python-versions/releases/download/3.9.19-9003651947/python-3.9.19-linux-22.04-x64.tar.gz"
},
{
"filename": "python-3.9.19-linux-24.04-x64.tar.gz",
"arch": "x64",
"platform": "linux",
"platform_version": "24.04",
"download_url": "https://github.com/actions/python-versions/releases/download/3.9.19-9003651947/python-3.9.19-linux-24.04-x64.tar.gz"
}
]
},