diff --git a/.azure-pipelines/azure-pipelines-osx.yml b/.azure-pipelines/azure-pipelines-osx.yml index 4da4351b..d1d3f47f 100755 --- a/.azure-pipelines/azure-pipelines-osx.yml +++ b/.azure-pipelines/azure-pipelines-osx.yml @@ -12,48 +12,74 @@ jobs: CONFIG: osx_64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno UPLOAD_PACKAGES: 'True' VMIMAGE: macOS-15 - store_build_artifacts: false + build_workspace_dir: ~/miniforge3/conda-bld + store_build_artifacts: true + tools_install_dir: ~/miniforge3 + SHORT_CONFIG: osx_64_build_typedebugchannel_targetscon_h5e478946 osx_64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes: CONFIG: osx_64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes UPLOAD_PACKAGES: 'True' VMIMAGE: macOS-15 - store_build_artifacts: false + build_workspace_dir: ~/miniforge3/conda-bld + store_build_artifacts: true + tools_install_dir: ~/miniforge3 + SHORT_CONFIG: osx_64_build_typedebugchannel_targetscon_h116d3356 osx_64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno: CONFIG: osx_64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno UPLOAD_PACKAGES: 'True' VMIMAGE: macOS-15 - store_build_artifacts: false + build_workspace_dir: ~/miniforge3/conda-bld + store_build_artifacts: true + tools_install_dir: ~/miniforge3 + SHORT_CONFIG: osx_64_build_typereleasechannel_targetsc_h425d4db0 osx_64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes: CONFIG: osx_64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes UPLOAD_PACKAGES: 'True' VMIMAGE: macOS-15 - store_build_artifacts: false + build_workspace_dir: ~/miniforge3/conda-bld + store_build_artifacts: true + tools_install_dir: ~/miniforge3 + SHORT_CONFIG: osx_64_build_typereleasechannel_targetsc_haa8f77b8 osx_arm64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno: CONFIG: osx_arm64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno UPLOAD_PACKAGES: 'True' - VMIMAGE: macOS-15 - store_build_artifacts: false + VMIMAGE: macOS-15-arm64 + build_workspace_dir: ~/miniforge3/conda-bld + store_build_artifacts: true + tools_install_dir: ~/miniforge3 + SHORT_CONFIG: osx_arm64_build_typedebugchannel_targets_h4a1f0d05 osx_arm64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes: CONFIG: osx_arm64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes UPLOAD_PACKAGES: 'True' - VMIMAGE: macOS-15 - store_build_artifacts: false + VMIMAGE: macOS-15-arm64 + build_workspace_dir: ~/miniforge3/conda-bld + store_build_artifacts: true + tools_install_dir: ~/miniforge3 + SHORT_CONFIG: osx_arm64_build_typedebugchannel_targets_h49dbe0c1 osx_arm64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno: CONFIG: osx_arm64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno UPLOAD_PACKAGES: 'True' - VMIMAGE: macOS-15 - store_build_artifacts: false + VMIMAGE: macOS-15-arm64 + build_workspace_dir: ~/miniforge3/conda-bld + store_build_artifacts: true + tools_install_dir: ~/miniforge3 + SHORT_CONFIG: osx_arm64_build_typereleasechannel_targe_h0d9a29af osx_arm64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes: CONFIG: osx_arm64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes UPLOAD_PACKAGES: 'True' - VMIMAGE: macOS-15 - store_build_artifacts: false + VMIMAGE: macOS-15-arm64 + build_workspace_dir: ~/miniforge3/conda-bld + store_build_artifacts: true + tools_install_dir: ~/miniforge3 + SHORT_CONFIG: osx_arm64_build_typereleasechannel_targe_h92a1d5a6 timeoutInMinutes: 360 variables: {} steps: # TODO: Fast finish on azure pipelines? - script: | + export MINIFORGE_HOME=$(tools_install_dir) + export CONDA_BLD_PATH=$(build_workspace_dir) export CI=azure export flow_run_id=azure_$(Build.BuildNumber).$(System.JobAttempt) export remote_url=$(Build.Repository.Uri) @@ -72,3 +98,34 @@ jobs: BINSTAR_TOKEN: $(BINSTAR_TOKEN) FEEDSTOCK_TOKEN: $(FEEDSTOCK_TOKEN) STAGING_BINSTAR_TOKEN: $(STAGING_BINSTAR_TOKEN) + + - script: | + export MINIFORGE_HOME=$(tools_install_dir) + export CONDA_BLD_PATH=$(build_workspace_dir) + export CI=azure + export CI_RUN_ID=$(build.BuildNumber).$(system.JobAttempt) + export FEEDSTOCK_NAME=$(basename ${BUILD_REPOSITORY_NAME}) + export ARTIFACT_STAGING_DIR="$(Build.ArtifactStagingDirectory)" + # Archive everything in CONDA_BLD_PATH except environments + export BLD_ARTIFACT_PREFIX=conda_artifacts + if [[ "$AGENT_JOBSTATUS" == "Failed" ]]; then + # Archive the CONDA_BLD_PATH environments only when the job fails + export ENV_ARTIFACT_PREFIX=conda_envs + fi + ./.scripts/create_conda_build_artifacts.sh + displayName: Prepare conda build artifacts + condition: and(succeededOrFailed(), eq(variables.store_build_artifacts, true)) + + - task: PublishPipelineArtifact@1 + displayName: Store conda build artifacts + condition: not(eq(variables.BLD_ARTIFACT_PATH, '')) + inputs: + targetPath: $(BLD_ARTIFACT_PATH) + artifactName: $(BLD_ARTIFACT_NAME) + + - task: PublishPipelineArtifact@1 + displayName: Store conda build environment artifacts + condition: not(eq(variables.ENV_ARTIFACT_PATH, '')) + inputs: + targetPath: $(ENV_ARTIFACT_PATH) + artifactName: $(ENV_ARTIFACT_NAME) diff --git a/.azure-pipelines/azure-pipelines-win.yml b/.azure-pipelines/azure-pipelines-win.yml index 8fbb50c4..e7142353 100755 --- a/.azure-pipelines/azure-pipelines-win.yml +++ b/.azure-pipelines/azure-pipelines-win.yml @@ -11,23 +11,33 @@ jobs: win_64_freethreadingno: CONFIG: win_64_freethreadingno UPLOAD_PACKAGES: 'True' - store_build_artifacts: false + build_workspace_dir: D:\\bld\\ + store_build_artifacts: true + tools_install_dir: D:\Miniforge + SHORT_CONFIG: win_64_freethreadingno win_64_freethreadingyes: CONFIG: win_64_freethreadingyes UPLOAD_PACKAGES: 'True' - store_build_artifacts: false + build_workspace_dir: D:\\bld\\ + store_build_artifacts: true + tools_install_dir: D:\Miniforge + SHORT_CONFIG: win_64_freethreadingyes win_arm64_freethreadingno: CONFIG: win_arm64_freethreadingno UPLOAD_PACKAGES: 'True' - store_build_artifacts: false + build_workspace_dir: C:\\bld\\ + store_build_artifacts: true + tools_install_dir: C:\Miniforge + SHORT_CONFIG: win_arm64_freethreadingno win_arm64_freethreadingyes: CONFIG: win_arm64_freethreadingyes UPLOAD_PACKAGES: 'True' - store_build_artifacts: false + build_workspace_dir: C:\\bld\\ + store_build_artifacts: true + tools_install_dir: C:\Miniforge + SHORT_CONFIG: win_arm64_freethreadingyes timeoutInMinutes: 360 variables: - CONDA_BLD_PATH: D:\\bld\\ - MINIFORGE_HOME: D:\Miniforge UPLOAD_TEMP: D:\\tmp steps: @@ -36,8 +46,8 @@ jobs: call ".scripts\run_win_build.bat" displayName: Run Windows build env: - MINIFORGE_HOME: $(MINIFORGE_HOME) - CONDA_BLD_PATH: $(CONDA_BLD_PATH) + MINIFORGE_HOME: $(tools_install_dir) + CONDA_BLD_PATH: $(build_workspace_dir) PYTHONUNBUFFERED: 1 CONFIG: $(CONFIG) CI: azure @@ -49,3 +59,32 @@ jobs: BINSTAR_TOKEN: $(BINSTAR_TOKEN) FEEDSTOCK_TOKEN: $(FEEDSTOCK_TOKEN) STAGING_BINSTAR_TOKEN: $(STAGING_BINSTAR_TOKEN) + + - script: | + set MINIFORGE_HOME=$(tools_install_dir) + set CONDA_BLD_PATH=$(build_workspace_dir) + set CI=azure + set CI_RUN_ID=$(build.BuildNumber).$(system.JobAttempt) + set FEEDSTOCK_NAME=$(build.Repository.Name) + set ARTIFACT_STAGING_DIR=$(Build.ArtifactStagingDirectory) + set BLD_ARTIFACT_PREFIX=conda_artifacts + if "%AGENT_JOBSTATUS%" == "Failed" ( + set ENV_ARTIFACT_PREFIX=conda_envs + ) + call ".scripts\create_conda_build_artifacts.bat" + displayName: Prepare conda build artifacts + condition: and(succeededOrFailed(), eq(variables.store_build_artifacts, true)) + + - task: PublishPipelineArtifact@1 + displayName: Store conda build artifacts + condition: not(eq(variables.BLD_ARTIFACT_PATH, '')) + inputs: + targetPath: $(BLD_ARTIFACT_PATH) + artifactName: $(BLD_ARTIFACT_NAME) + + - task: PublishPipelineArtifact@1 + displayName: Store conda build environment artifacts + condition: not(eq(variables.ENV_ARTIFACT_PATH, '')) + inputs: + targetPath: $(ENV_ARTIFACT_PATH) + artifactName: $(ENV_ARTIFACT_NAME) diff --git a/.ci_support/linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno.yaml b/.ci_support/linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno.yaml index fd15ad54..a926bb76 100644 --- a/.ci_support/linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno.yaml +++ b/.ci_support/linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno.yaml @@ -19,7 +19,7 @@ cxx_compiler: cxx_compiler_version: - '14' docker_image: -- quay.io/condaforge/linux-anvil-x86_64:alma9 +- quay.io/condaforge/linux-anvil-aarch64:alma9 expat: - '2' freethreading: diff --git a/.ci_support/linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes.yaml b/.ci_support/linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes.yaml index 1b77335e..e326b66b 100644 --- a/.ci_support/linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes.yaml +++ b/.ci_support/linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes.yaml @@ -19,7 +19,7 @@ cxx_compiler: cxx_compiler_version: - '14' docker_image: -- quay.io/condaforge/linux-anvil-x86_64:alma9 +- quay.io/condaforge/linux-anvil-aarch64:alma9 expat: - '2' freethreading: diff --git a/.ci_support/linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno.yaml b/.ci_support/linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno.yaml index 9438623e..706f1686 100644 --- a/.ci_support/linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno.yaml +++ b/.ci_support/linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno.yaml @@ -19,7 +19,7 @@ cxx_compiler: cxx_compiler_version: - '14' docker_image: -- quay.io/condaforge/linux-anvil-x86_64:alma9 +- quay.io/condaforge/linux-anvil-aarch64:alma9 expat: - '2' freethreading: diff --git a/.ci_support/linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes.yaml b/.ci_support/linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes.yaml index 94c39101..6fea0031 100644 --- a/.ci_support/linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes.yaml +++ b/.ci_support/linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes.yaml @@ -19,7 +19,7 @@ cxx_compiler: cxx_compiler_version: - '14' docker_image: -- quay.io/condaforge/linux-anvil-x86_64:alma9 +- quay.io/condaforge/linux-anvil-aarch64:alma9 expat: - '2' freethreading: diff --git a/.github/workflows/conda-build.yml b/.github/workflows/conda-build.yml index 555761c2..a09c673a 100644 --- a/.github/workflows/conda-build.yml +++ b/.github/workflows/conda-build.yml @@ -23,77 +23,125 @@ jobs: matrix: include: - CONFIG: linux_64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_64_build_typedebugchannel_targetsc_h10d856d4 UPLOAD_PACKAGES: True os: ubuntu runs_on: ['ubuntu-latest'] DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_64_build_typedebugchannel_targetsc_hf83d9e2d UPLOAD_PACKAGES: True os: ubuntu runs_on: ['ubuntu-latest'] DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_64_build_typereleasechannel_target_h01f3c156 UPLOAD_PACKAGES: True os: ubuntu runs_on: ['ubuntu-latest'] DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_64_build_typereleasechannel_target_hf5ff4d16 UPLOAD_PACKAGES: True os: ubuntu runs_on: ['ubuntu-latest'] DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_aarch64_build_typedebugchannel_tar_hd2db0a21 UPLOAD_PACKAGES: True os: ubuntu - runs_on: ['ubuntu-latest'] - DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + runs_on: ['ubuntu-24.04-arm'] + DOCKER_IMAGE: quay.io/condaforge/linux-anvil-aarch64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_aarch64_build_typedebugchannel_tar_h51de9693 UPLOAD_PACKAGES: True os: ubuntu - runs_on: ['ubuntu-latest'] - DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + runs_on: ['ubuntu-24.04-arm'] + DOCKER_IMAGE: quay.io/condaforge/linux-anvil-aarch64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_aarch64_build_typereleasechannel_t_hccc48f4a UPLOAD_PACKAGES: True os: ubuntu - runs_on: ['ubuntu-latest'] - DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + runs_on: ['ubuntu-24.04-arm'] + DOCKER_IMAGE: quay.io/condaforge/linux-anvil-aarch64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_aarch64_build_typereleasechannel_t_h78d2c7f5 UPLOAD_PACKAGES: True os: ubuntu - runs_on: ['ubuntu-latest'] - DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + runs_on: ['ubuntu-24.04-arm'] + DOCKER_IMAGE: quay.io/condaforge/linux-anvil-aarch64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_ppc64le_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_ppc64le_build_typedebugchannel_tar_hac8bb296 UPLOAD_PACKAGES: True os: ubuntu runs_on: ['ubuntu-latest'] DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_ppc64le_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_ppc64le_build_typedebugchannel_tar_hb74ed675 UPLOAD_PACKAGES: True os: ubuntu runs_on: ['ubuntu-latest'] DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_ppc64le_build_typereleasechannel_targetsconda-forge_mainfreethreadingno - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_ppc64le_build_typereleasechannel_t_h5454d1d5 UPLOAD_PACKAGES: True os: ubuntu runs_on: ['ubuntu-latest'] DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: - CONFIG: linux_ppc64le_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes - STORE_BUILD_ARTIFACTS: False + STORE_BUILD_ARTIFACTS: True + SHORT_CONFIG: linux_ppc64le_build_typereleasechannel_t_hed84b2c3 UPLOAD_PACKAGES: True os: ubuntu runs_on: ['ubuntu-latest'] DOCKER_IMAGE: quay.io/condaforge/linux-anvil-x86_64:alma9 + tools_install_dir: ~/miniforge3 + build_workspace_dir: build_artifacts + docker_run_args: steps: - name: Checkout code @@ -103,11 +151,13 @@ jobs: id: build-linux if: matrix.os == 'ubuntu' env: + MINIFORGE_HOME: ${{ matrix.tools_install_dir }} + CONDA_BLD_PATH: ${{ matrix.build_workspace_dir }} CONFIG: ${{ matrix.CONFIG }} UPLOAD_PACKAGES: ${{ matrix.UPLOAD_PACKAGES }} DOCKER_IMAGE: ${{ matrix.DOCKER_IMAGE }} CI: github_actions - CONDA_FORGE_DOCKER_RUN_ARGS: "${{ matrix.CONDA_FORGE_DOCKER_RUN_ARGS }}" + CONDA_FORGE_DOCKER_RUN_ARGS: "${{ matrix.docker_run_args }}" BINSTAR_TOKEN: ${{ secrets.BINSTAR_TOKEN }} FEEDSTOCK_TOKEN: ${{ secrets.FEEDSTOCK_TOKEN }} STAGING_BINSTAR_TOKEN: ${{ secrets.STAGING_BINSTAR_TOKEN }} @@ -127,6 +177,8 @@ jobs: else export IS_PR_BUILD="False" fi + export MINIFORGE_HOME="${MINIFORGE_HOME/#~/${HOME}}" + export CONDA_BLD_PATH="${CONDA_BLD_PATH/#~/${HOME}}" echo "::endgroup::" ./.scripts/run_docker_build.sh @@ -134,6 +186,8 @@ jobs: id: build-macos if: matrix.os == 'macos' env: + MINIFORGE_HOME: ${{ matrix.tools_install_dir }} + CONDA_BLD_PATH: ${{ matrix.build_workspace_dir }} CONFIG: ${{ matrix.CONFIG }} UPLOAD_PACKAGES: ${{ matrix.UPLOAD_PACKAGES }} CI: github_actions @@ -152,6 +206,8 @@ jobs: else export IS_PR_BUILD="False" fi + export MINIFORGE_HOME="${MINIFORGE_HOME/#~/${HOME}}" + export CONDA_BLD_PATH="${CONDA_BLD_PATH/#~/${HOME}}" ./.scripts/run_osx_build.sh - name: Build on windows @@ -164,14 +220,88 @@ jobs: set "sha=%GITHUB_SHA%" call ".scripts\run_win_build.bat" env: - # default value; make it explicit, as it needs to match with artefact - # generation below. Not configurable for now, can be revisited later - CONDA_BLD_PATH: C:\bld - MINIFORGE_HOME: ${{ contains(runner.arch, 'ARM') && 'C' || 'D' }}:\Miniforge + MINIFORGE_HOME: ${{ matrix.tools_install_dir }} + CONDA_BLD_PATH: ${{ matrix.build_workspace_dir }} PYTHONUNBUFFERED: 1 CONFIG: ${{ matrix.CONFIG }} CI: github_actions UPLOAD_PACKAGES: ${{ matrix.UPLOAD_PACKAGES }} BINSTAR_TOKEN: ${{ secrets.BINSTAR_TOKEN }} FEEDSTOCK_TOKEN: ${{ secrets.FEEDSTOCK_TOKEN }} - STAGING_BINSTAR_TOKEN: ${{ secrets.STAGING_BINSTAR_TOKEN }} \ No newline at end of file + STAGING_BINSTAR_TOKEN: ${{ secrets.STAGING_BINSTAR_TOKEN }} + + - name: Determine build outcome + # this is to merge the status of the linux/osx/win builds into + # something we can easily reuse during artefact generation + id: determine-status + if: ${{ always() }} + shell: bash + env: + OS: ${{ matrix.os }} + run: | + if [[ "$OS" == "ubuntu" ]]; then + STATUS=${{ steps.build-linux.outcome }} + elif [[ "$OS" == "macos" ]]; then + STATUS=${{ steps.build-macos.outcome }} + elif [[ "$OS" == "windows" ]]; then + STATUS=${{ steps.build-windows.outcome }} + fi + if [ -z "$STATUS" ]; then + # steps that never ran will have empty status + STATUS="cancelled" + fi + echo "status=$STATUS" >> $GITHUB_OUTPUT + + - name: Prepare conda build artifacts + continue-on-error: true + id: prepare-artifacts + shell: bash + # we do not want to trigger artefact creation if the build was cancelled + if: ${{ always() && steps.determine-status.outputs.status != 'cancelled' && matrix.STORE_BUILD_ARTIFACTS }} + env: + CONDA_BLD_PATH: ${{ matrix.build_workspace_dir }} + CI: github_actions + CONFIG: ${{ matrix.CONFIG }} + SHORT_CONFIG: ${{ matrix.SHORT_CONFIG }} + JOB_STATUS: ${{ steps.determine-status.outputs.status }} + OS: ${{ matrix.os }} + run: | + export MINIFORGE_HOME="${MINIFORGE_HOME/#~/${HOME}}" + export CONDA_BLD_PATH="${CONDA_BLD_PATH/#~/${HOME}}" + export CI_RUN_ID=$GITHUB_RUN_ID + export FEEDSTOCK_NAME="$(basename $GITHUB_REPOSITORY)" + export ARTIFACT_STAGING_DIR="$GITHUB_WORKSPACE" + # Archive everything in CONDA_BLD_PATH except environments + # Archive the CONDA_BLD_PATH environments only when the job fails + # Use different prefix for successful and failed build artifacts + # so random failures don't prevent rebuilds from creating artifacts. + if [ $JOB_STATUS == "failure" ]; then + export BLD_ARTIFACT_PREFIX="conda_artifacts" + export ENV_ARTIFACT_PREFIX="conda_envs" + else + export BLD_ARTIFACT_PREFIX="conda_pkgs" + fi + if [ $OS == "windows" ]; then + pwsh -Command ". '.scripts/create_conda_build_artifacts.bat'" + else + ./.scripts/create_conda_build_artifacts.sh + fi + + - name: Store conda build artifacts + uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0 + if: ${{ always() && steps.prepare-artifacts.outcome == 'success' }} + with: + name: ${{ steps.prepare-artifacts.outputs.BLD_ARTIFACT_NAME }} + path: ${{ steps.prepare-artifacts.outputs.BLD_ARTIFACT_PATH }} + retention-days: 14 + continue-on-error: true + + - name: Store conda build environment artifacts + uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0 + # only relevant if build failed, see above + if: ${{ always() && steps.determine-status.outputs.status == 'failure' && steps.prepare-artifacts.outcome == 'success' }} + with: + name: ${{ steps.prepare-artifacts.outputs.ENV_ARTIFACT_NAME }} + path: ${{ steps.prepare-artifacts.outputs.ENV_ARTIFACT_PATH }} + retention-days: 14 + continue-on-error: true \ No newline at end of file diff --git a/.scripts/build_steps.sh b/.scripts/build_steps.sh index be060cb0..c83e212f 100755 --- a/.scripts/build_steps.sh +++ b/.scripts/build_steps.sh @@ -36,7 +36,7 @@ mv /opt/conda/conda-meta/history /opt/conda/conda-meta/history.$(date +%Y-%m-%d- echo > /opt/conda/conda-meta/history micromamba install --root-prefix ~/.conda --prefix /opt/conda \ --yes --override-channels --channel conda-forge --strict-channel-priority \ - pip python=3.12 conda-build conda-forge-ci-setup=4 "conda-build>=24.1" + pip python=3.12 conda-build conda-forge-ci-setup=4 "conda-build>=26.3" export CONDA_LIBMAMBA_SOLVER_NO_CHANNELS_FROM_INSTALLED=1 # set up the condarc diff --git a/.scripts/create_conda_build_artifacts.bat b/.scripts/create_conda_build_artifacts.bat new file mode 100755 index 00000000..6120712c --- /dev/null +++ b/.scripts/create_conda_build_artifacts.bat @@ -0,0 +1,77 @@ +setlocal enableextensions enabledelayedexpansion + +rem INPUTS (environment variables that need to be set before calling this script): +rem +rem CI (azure/github_actions/UNSET) +rem CI_RUN_ID (unique identifier for the CI job run) +rem FEEDSTOCK_NAME +rem CONFIG (build matrix configuration string) +rem SHORT_CONFIG (uniquely-shortened configuration string) +rem CONDA_BLD_PATH (path to the conda-bld directory) +rem ARTIFACT_STAGING_DIR (use working directory if unset) +rem BLD_ARTIFACT_PREFIX (prefix for the conda build artifact name, skip if unset) +rem ENV_ARTIFACT_PREFIX (prefix for the conda build environments artifact name, skip if unset) + +rem OUTPUTS +rem +rem BLD_ARTIFACT_NAME +rem BLD_ARTIFACT_PATH +rem ENV_ARTIFACT_NAME +rem ENV_ARTIFACT_PATH + +rem Check that the conda-build directory exists +if not exist %CONDA_BLD_PATH% ( + echo conda-build directory does not exist + exit 1 +) + +if not defined ARTIFACT_STAGING_DIR ( + rem Set staging dir to the working dir + set ARTIFACT_STAGING_DIR=%cd% +) + +rem Set a unique ID for the artifact(s), specialized for this particular job run +set ARTIFACT_UNIQUE_ID=%CI_RUN_ID%_%CONFIG% +if not "%ARTIFACT_UNIQUE_ID%" == "%ARTIFACT_UNIQUE_ID:~0,80%" ( + set ARTIFACT_UNIQUE_ID=%CI_RUN_ID%_%SHORT_CONFIG% +) + +rem Make the build artifact zip +if defined BLD_ARTIFACT_PREFIX ( + set BLD_ARTIFACT_NAME=%BLD_ARTIFACT_PREFIX%_%ARTIFACT_UNIQUE_ID% + echo BLD_ARTIFACT_NAME: !BLD_ARTIFACT_NAME! + + set "BLD_ARTIFACT_PATH=%ARTIFACT_STAGING_DIR%\%FEEDSTOCK_NAME%_%BLD_ARTIFACT_PREFIX%_%ARCHIVE_UNIQUE_ID%.zip" + 7z a "!BLD_ARTIFACT_PATH!" "%CONDA_BLD_PATH%" -xr^^!.git/ -xr^^!_*_env*/ -xr^^!*_cache/ -bb + if errorlevel 1 exit 1 + echo BLD_ARTIFACT_PATH: !BLD_ARTIFACT_PATH! + + if "%CI%" == "azure" ( + echo ##vso[task.setVariable variable=BLD_ARTIFACT_NAME]!BLD_ARTIFACT_NAME! + echo ##vso[task.setVariable variable=BLD_ARTIFACT_PATH]!BLD_ARTIFACT_PATH! + ) + if "%CI%" == "github_actions" ( + echo BLD_ARTIFACT_NAME=!BLD_ARTIFACT_NAME!>> !GITHUB_OUTPUT! + echo BLD_ARTIFACT_PATH=!BLD_ARTIFACT_PATH!>> !GITHUB_OUTPUT! + ) +) + +rem Make the environments artifact zip +if defined ENV_ARTIFACT_PREFIX ( + set ENV_ARTIFACT_NAME=!ENV_ARTIFACT_PREFIX!_%ARTIFACT_UNIQUE_ID% + echo ENV_ARTIFACT_NAME: !ENV_ARTIFACT_NAME! + + set "ENV_ARTIFACT_PATH=%ARTIFACT_STAGING_DIR%\%FEEDSTOCK_NAME%_%ENV_ARTIFACT_PREFIX%_%ARCHIVE_UNIQUE_ID%.zip" + 7z a "!ENV_ARTIFACT_PATH!" -r "%CONDA_BLD_PATH%"/_*_env*/ -bb + if errorlevel 1 exit 1 + echo ENV_ARTIFACT_PATH: !ENV_ARTIFACT_PATH! + + if "%CI%" == "azure" ( + echo ##vso[task.setVariable variable=ENV_ARTIFACT_NAME]!ENV_ARTIFACT_NAME! + echo ##vso[task.setVariable variable=ENV_ARTIFACT_PATH]!ENV_ARTIFACT_PATH! + ) + if "%CI%" == "github_actions" ( + echo ENV_ARTIFACT_NAME=!ENV_ARTIFACT_NAME!>> !GITHUB_OUTPUT! + echo ENV_ARTIFACT_PATH=!ENV_ARTIFACT_PATH!>> !GITHUB_OUTPUT! + ) +) diff --git a/.scripts/create_conda_build_artifacts.sh b/.scripts/create_conda_build_artifacts.sh new file mode 100755 index 00000000..1e3acc78 --- /dev/null +++ b/.scripts/create_conda_build_artifacts.sh @@ -0,0 +1,113 @@ +#!/usr/bin/env bash + +# INPUTS (environment variables that need to be set before calling this script): +# +# CI (azure/github_actions/UNSET) +# CI_RUN_ID (unique identifier for the CI job run) +# FEEDSTOCK_NAME +# CONFIG (build matrix configuration string) +# SHORT_CONFIG (uniquely-shortened configuration string) +# CONDA_BLD_PATH (path to the conda-bld directory) +# ARTIFACT_STAGING_DIR (use working directory if unset) +# BLD_ARTIFACT_PREFIX (prefix for the conda build artifact name, skip if unset) +# ENV_ARTIFACT_PREFIX (prefix for the conda build environments artifact name, skip if unset) + +# OUTPUTS +# +# BLD_ARTIFACT_NAME +# BLD_ARTIFACT_PATH +# ENV_ARTIFACT_NAME +# ENV_ARTIFACT_PATH + +source .scripts/logging_utils.sh + +# DON'T do set -x, because it results in double echo-ing pipeline commands +# and that might end up inserting extraneous quotation marks in output variables +set -e + +# Check that the conda-build directory exists +if [ ! -d "$CONDA_BLD_PATH" ]; then + echo "conda-build directory does not exist" + exit 1 +fi + +# Set staging dir to the working dir, in Windows style if applicable +if [[ -z "${ARTIFACT_STAGING_DIR}" ]]; then + if pwd -W; then + ARTIFACT_STAGING_DIR=$(pwd -W) + else + ARTIFACT_STAGING_DIR=$PWD + fi +fi +echo "ARTIFACT_STAGING_DIR: $ARTIFACT_STAGING_DIR" + +FEEDSTOCK_ROOT=$(cd "$(dirname "$0")/.."; pwd;) +if [ -z ${FEEDSTOCK_NAME} ]; then + export FEEDSTOCK_NAME=$(basename ${FEEDSTOCK_ROOT}) +fi + +# Set a unique ID for the artifact(s), specialized for this particular job run +ARTIFACT_UNIQUE_ID="${CI_RUN_ID}_${CONFIG}" +if [[ ${#ARTIFACT_UNIQUE_ID} -gt 80 ]]; then + ARTIFACT_UNIQUE_ID="${CI_RUN_ID}_${SHORT_CONFIG}" +fi +echo "ARTIFACT_UNIQUE_ID: $ARTIFACT_UNIQUE_ID" + +# Set a descriptive ID for the archive(s), specialized for this particular job run +ARCHIVE_UNIQUE_ID="${CI_RUN_ID}_${CONFIG}" + +# Make the build artifact zip +if [[ ! -z "$BLD_ARTIFACT_PREFIX" ]]; then + export BLD_ARTIFACT_NAME="${BLD_ARTIFACT_PREFIX}_${ARTIFACT_UNIQUE_ID}" + export BLD_ARTIFACT_PATH="${ARTIFACT_STAGING_DIR}/${FEEDSTOCK_NAME}_${BLD_ARTIFACT_PREFIX}_${ARCHIVE_UNIQUE_ID}.zip" + + ( startgroup "Archive conda build directory" ) 2> /dev/null + + # Try 7z and fall back to zip if it fails (for cross-platform use) + if ! 7z a "$BLD_ARTIFACT_PATH" "$CONDA_BLD_PATH" '-xr!.git/' '-xr!_*_env*/' '-xr!*_cache/' -bb; then + pushd "$CONDA_BLD_PATH" + zip -r -y -T "$BLD_ARTIFACT_PATH" . -x '*.git/*' '*_*_env*/*' '*_cache/*' + popd + fi + + ( endgroup "Archive conda build directory" ) 2> /dev/null + + echo "BLD_ARTIFACT_NAME: $BLD_ARTIFACT_NAME" + echo "BLD_ARTIFACT_PATH: $BLD_ARTIFACT_PATH" + + if [[ "$CI" == "azure" ]]; then + echo "##vso[task.setVariable variable=BLD_ARTIFACT_NAME]$BLD_ARTIFACT_NAME" + echo "##vso[task.setVariable variable=BLD_ARTIFACT_PATH]$BLD_ARTIFACT_PATH" + elif [[ "$CI" == "github_actions" ]]; then + echo "BLD_ARTIFACT_NAME=$BLD_ARTIFACT_NAME" >> $GITHUB_OUTPUT + echo "BLD_ARTIFACT_PATH=$BLD_ARTIFACT_PATH" >> $GITHUB_OUTPUT + fi +fi + +# Make the environments artifact zip +if [[ ! -z "$ENV_ARTIFACT_PREFIX" ]]; then + export ENV_ARTIFACT_NAME="${ENV_ARTIFACT_PREFIX}_${ARTIFACT_UNIQUE_ID}" + export ENV_ARTIFACT_PATH="${ARTIFACT_STAGING_DIR}/${FEEDSTOCK_NAME}_${ENV_ARTIFACT_PREFIX}_${ARCHIVE_UNIQUE_ID}.zip" + + ( startgroup "Archive conda build environments" ) 2> /dev/null + + # Try 7z and fall back to zip if it fails (for cross-platform use) + if ! 7z a "$ENV_ARTIFACT_PATH" -r "$CONDA_BLD_PATH"/'_*_env*/' -bb; then + pushd "$CONDA_BLD_PATH" + zip -r -y -T "$ENV_ARTIFACT_PATH" . -i '*_*_env*/*' + popd + fi + + ( endgroup "Archive conda build environments" ) 2> /dev/null + + echo "ENV_ARTIFACT_NAME: $ENV_ARTIFACT_NAME" + echo "ENV_ARTIFACT_PATH: $ENV_ARTIFACT_PATH" + + if [[ "$CI" == "azure" ]]; then + echo "##vso[task.setVariable variable=ENV_ARTIFACT_NAME]$ENV_ARTIFACT_NAME" + echo "##vso[task.setVariable variable=ENV_ARTIFACT_PATH]$ENV_ARTIFACT_PATH" + elif [[ "$CI" == "github_actions" ]]; then + echo "ENV_ARTIFACT_NAME=$ENV_ARTIFACT_NAME" >> $GITHUB_OUTPUT + echo "ENV_ARTIFACT_PATH=$ENV_ARTIFACT_PATH" >> $GITHUB_OUTPUT + fi +fi diff --git a/.scripts/run_osx_build.sh b/.scripts/run_osx_build.sh index bac7141a..b0eda55c 100755 --- a/.scripts/run_osx_build.sh +++ b/.scripts/run_osx_build.sh @@ -26,7 +26,7 @@ chmod +x "${micromamba_exe}" echo "Creating environment" "${micromamba_exe}" create --yes --root-prefix "${MAMBA_ROOT_PREFIX}" --prefix "${MINIFORGE_HOME}" \ --channel conda-forge \ - pip python=3.12 conda-build conda-forge-ci-setup=4 "conda-build>=24.1" + pip python=3.12 conda-build conda-forge-ci-setup=4 "conda-build>=26.3" echo "Moving pkgs cache from ${MAMBA_ROOT_PREFIX} to ${MINIFORGE_HOME}" mv "${MAMBA_ROOT_PREFIX}/pkgs" "${MINIFORGE_HOME}" echo "Cleaning up micromamba" @@ -73,7 +73,7 @@ if [[ "${OSX_SDK_DIR:-}" == "" ]]; then /usr/bin/sudo chown "${USER}" "${OSX_SDK_DIR}" fi else - if tmpf=$(mktemp -p "$OSX_SDK_DIR" tmp.XXXXXXXX 2>/dev/null); then + if tmpf=$(mktemp "$OSX_SDK_DIR"/tmp.XXXXXXXX 2>/dev/null); then rm -f "$tmpf" echo "OSX_SDK_DIR is writeable without sudo, continuing" else diff --git a/.scripts/run_win_build.bat b/.scripts/run_win_build.bat index 27c552b1..c07d98e6 100755 --- a/.scripts/run_win_build.bat +++ b/.scripts/run_win_build.bat @@ -31,7 +31,7 @@ if !errorlevel! neq 0 exit /b !errorlevel! echo Creating environment call "%MICROMAMBA_EXE%" create --yes --root-prefix "%MAMBA_ROOT_PREFIX%" --prefix "%MINIFORGE_HOME%" ^ --channel conda-forge ^ - pip python=3.12 conda-build conda-forge-ci-setup=4 "conda-build>=24.1" + pip python=3.12 conda-build conda-forge-ci-setup=4 "conda-build>=26.3" if !errorlevel! neq 0 exit /b !errorlevel! echo Removing %MAMBA_ROOT_PREFIX% del /S /Q "%MAMBA_ROOT_PREFIX%" >nul diff --git a/README.md b/README.md index d5dd60e1..dcf4795e 100644 --- a/README.md +++ b/README.md @@ -45,7 +45,14 @@ Current build status ==================== - +
+ + + @@ -59,90 +66,6 @@ Current build status
GitHub Actions + + + +
Azure
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
VariantStatus
linux_64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno - - variant - -
linux_64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes - - variant - -
linux_64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno - - variant - -
linux_64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes - - variant - -
linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno - - variant - -
linux_aarch64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes - - variant - -
linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingno - - variant - -
linux_aarch64_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes - - variant - -
linux_ppc64le_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno - - variant - -
linux_ppc64le_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingyes - - variant - -
linux_ppc64le_build_typereleasechannel_targetsconda-forge_mainfreethreadingno - - variant - -
linux_ppc64le_build_typereleasechannel_targetsconda-forge_mainfreethreadingyes - - variant - -
osx_64_build_typedebugchannel_targetsconda-forge_python_debugfreethreadingno @@ -212,20 +135,6 @@ Current build status variant
win_arm64_freethreadingno - - variant - -
win_arm64_freethreadingyes - - variant - -
diff --git a/conda-forge.yml b/conda-forge.yml index ab94597a..d04fdbba 100644 --- a/conda-forge.yml +++ b/conda-forge.yml @@ -6,9 +6,7 @@ bot: - '3.12' - '3.13' build_platform: - linux_aarch64: linux_64 linux_ppc64le: linux_64 - osx_arm64: osx_64 win_arm64: win_64 conda_build: pkg_format: '2' @@ -18,5 +16,8 @@ github: tooling_branch_name: main provider: linux_aarch64: default - linux_ppc64le: native + osx_arm64: default test: native_and_emulated +workflow_settings: + store_build_artifacts: + - value: true diff --git a/recipe/meta.yaml b/recipe/meta.yaml index ca2344cd..793e4219 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -1,4 +1,4 @@ -{% set version = "3.14.5" %} +{% set version = "3.14.6" %} {% set dev = "" %} {% set dev_ = "" %} {% set ver2 = '.'.join(version.split('.')[0:2]) %} @@ -46,7 +46,7 @@ package: source: - url: https://www.python.org/ftp/python/{{ version }}/Python-{{ version }}{{ dev }}.tar.xz # sha256 from: https://www.python.org/downloads/release/python-{{ ver3nd }}{{ dev }}/ - sha256: 7e32597b99e5d9a39abed35de4693fa169df3e5850d4c334337ffd6a19a36db6 + sha256: 143b1dddefaec3bd2e21e3b839b34a2b7fb9842272883c576420d605e9f30c63 patches: - patches/0001-Win32-Change-FD_SETSIZE-from-512-to-2048.patch - patches/0002-Win32-Do-not-download-externals.patch diff --git a/recipe/patches/0001-Win32-Change-FD_SETSIZE-from-512-to-2048.patch b/recipe/patches/0001-Win32-Change-FD_SETSIZE-from-512-to-2048.patch index 896bca9a..2c182580 100644 --- a/recipe/patches/0001-Win32-Change-FD_SETSIZE-from-512-to-2048.patch +++ b/recipe/patches/0001-Win32-Change-FD_SETSIZE-from-512-to-2048.patch @@ -1,4 +1,4 @@ -From beeefd6b9b6587c443b9822f0a1799ba02b1bfdf Mon Sep 17 00:00:00 2001 +From 48fcc7c4d3d88ca7ffab052cfbee27512901d458 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Wed, 16 Aug 2017 11:53:55 +0100 Subject: [PATCH 01/26] Win32: Change FD_SETSIZE from 512 to 2048 @@ -9,7 +9,7 @@ https://github.com/ContinuumIO/anaconda-issues/issues/1241 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Modules/selectmodule.c b/Modules/selectmodule.c -index d234d504cb5..3856307c611 100644 +index 42bf1157ccc..fb3c27a9ac5 100644 --- a/Modules/selectmodule.c +++ b/Modules/selectmodule.c @@ -44,7 +44,7 @@ diff --git a/recipe/patches/0002-Win32-Do-not-download-externals.patch b/recipe/patches/0002-Win32-Do-not-download-externals.patch index 734dbe6c..ee286aac 100644 --- a/recipe/patches/0002-Win32-Do-not-download-externals.patch +++ b/recipe/patches/0002-Win32-Do-not-download-externals.patch @@ -1,4 +1,4 @@ -From f75489f65b55fab066087b2bcf76f203f93025bc Mon Sep 17 00:00:00 2001 +From d27b283f6f7b7372271cc862a0a0ae426815010e Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Thu, 7 Sep 2017 11:35:47 +0100 Subject: [PATCH 02/26] Win32: Do not download externals diff --git a/recipe/patches/0003-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch b/recipe/patches/0003-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch index 8419dfcd..a4d86b2a 100644 --- a/recipe/patches/0003-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch +++ b/recipe/patches/0003-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch @@ -1,4 +1,4 @@ -From 8a72c28a7dde7e859ea1f26b654d18f36eb95774 Mon Sep 17 00:00:00 2001 +From 8eec70e4cde56e34cef8d23083a08b9b4833d20d Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Tue, 5 Dec 2017 22:47:59 +0000 Subject: [PATCH 03/26] Fix find_library so that it looks in sys.prefix/lib diff --git a/recipe/patches/0004-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch b/recipe/patches/0004-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch index cde1f1ae..df164d2e 100644 --- a/recipe/patches/0004-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch +++ b/recipe/patches/0004-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch @@ -1,4 +1,4 @@ -From 8db56658e2d81686aeef6f256227fc1251c1def4 Mon Sep 17 00:00:00 2001 +From 6ef047bc92544cc2bb50f89d6f1746397efb4b04 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Sat, 27 Oct 2018 18:48:30 +0100 Subject: [PATCH 04/26] Disable registry lookup unless CONDA_PY_ALLOW_REG_PATHS diff --git a/recipe/patches/0005-Unvendor-openssl.patch b/recipe/patches/0005-Unvendor-openssl.patch index 1b67952d..06ec5660 100644 --- a/recipe/patches/0005-Unvendor-openssl.patch +++ b/recipe/patches/0005-Unvendor-openssl.patch @@ -1,4 +1,4 @@ -From b87d9909684a5d1ff1071f45d2a4373d8039a40b Mon Sep 17 00:00:00 2001 +From aabd5c80763b1ce8c1220b9febccccc590ca7611 Mon Sep 17 00:00:00 2001 From: Nehal J Wani Date: Sat, 24 Nov 2018 20:38:02 -0600 Subject: [PATCH 05/26] Unvendor openssl @@ -90,7 +90,7 @@ index 7ca750dda8f..17eee400ebb 100644 diff --git a/PCbuild/python.props b/PCbuild/python.props -index cc4103e99a6..253aa66f477 100644 +index ce4a7781fbd..253aa66f477 100644 --- a/PCbuild/python.props +++ b/PCbuild/python.props @@ -68,6 +68,7 @@ @@ -112,8 +112,8 @@ index cc4103e99a6..253aa66f477 100644 - $(libffiDir)$(ArchName)\ - $(libffiOutDir)include $(ExternalsDir)\mpdecimal-4.0.0\ -- $(ExternalsDir)openssl-3.0.20\ -- $(ExternalsDir)openssl-bin-3.0.20\$(ArchName)\ +- $(ExternalsDir)openssl-3.5.7\ +- $(ExternalsDir)openssl-bin-3.5.7\$(ArchName)\ - $(opensslOutDir)include $(ExternalsDir)\nasm-2.11.06\ - $(ExternalsDir)\zlib-1.3.1\ diff --git a/recipe/patches/0006-Unvendor-sqlite3.patch b/recipe/patches/0006-Unvendor-sqlite3.patch index f87cf2d3..595aaf1b 100644 --- a/recipe/patches/0006-Unvendor-sqlite3.patch +++ b/recipe/patches/0006-Unvendor-sqlite3.patch @@ -1,4 +1,4 @@ -From b293787cba0f0f51b514657b40c59e00a0df449c Mon Sep 17 00:00:00 2001 +From ef9755d84ef3dfd8fdbe8e10363528da21afe502 Mon Sep 17 00:00:00 2001 From: Nehal J Wani Date: Tue, 5 Oct 2021 12:42:06 -0700 Subject: [PATCH 06/26] Unvendor sqlite3 diff --git a/recipe/patches/0007-Add-CondaEcosystemModifyDllSearchPath.patch b/recipe/patches/0007-Add-CondaEcosystemModifyDllSearchPath.patch index 581261ee..f406f87b 100644 --- a/recipe/patches/0007-Add-CondaEcosystemModifyDllSearchPath.patch +++ b/recipe/patches/0007-Add-CondaEcosystemModifyDllSearchPath.patch @@ -1,4 +1,4 @@ -From 76eba309f2a62780d7b720085c47f9502073e83c Mon Sep 17 00:00:00 2001 +From aeb6945890d75f21e022290f811bb0bd000e3369 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Tue, 24 Dec 2019 18:37:17 +0100 Subject: [PATCH 07/26] Add CondaEcosystemModifyDllSearchPath() @@ -33,7 +33,7 @@ Co-authored-by: Isuru Fernando 1 file changed, 95 insertions(+) diff --git a/Python/pylifecycle.c b/Python/pylifecycle.c -index 6963635213a..1790d5aad25 100644 +index 6241d6ddca1..fe2120940d2 100644 --- a/Python/pylifecycle.c +++ b/Python/pylifecycle.c @@ -80,6 +80,10 @@ diff --git a/recipe/patches/0008-Doing-d1trimfile.patch b/recipe/patches/0008-Doing-d1trimfile.patch index 715dbfd4..ecf355e7 100644 --- a/recipe/patches/0008-Doing-d1trimfile.patch +++ b/recipe/patches/0008-Doing-d1trimfile.patch @@ -1,4 +1,4 @@ -From 1ad68baafb6b6173f43a688ee2396be5bb80d716 Mon Sep 17 00:00:00 2001 +From 942cda22db307772ca4254743eae0f7bcc328641 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Tue, 31 Dec 2019 21:47:47 +0100 Subject: [PATCH 08/26] Doing d1trimfile @@ -429,7 +429,7 @@ index 4e721e8ce09..3fec7516ed5 100644 \ No newline at end of file + diff --git a/PCbuild/_testcapi.vcxproj b/PCbuild/_testcapi.vcxproj -index a68f15d25aa..5c42f15c312 100644 +index 51c4bcc6b47..ccc81a417fa 100644 --- a/PCbuild/_testcapi.vcxproj +++ b/PCbuild/_testcapi.vcxproj @@ -92,6 +92,26 @@ diff --git a/recipe/patches/0009-cross-compile-darwin.patch b/recipe/patches/0009-cross-compile-darwin.patch index 62c85f72..7bf70722 100644 --- a/recipe/patches/0009-cross-compile-darwin.patch +++ b/recipe/patches/0009-cross-compile-darwin.patch @@ -1,4 +1,4 @@ -From 28791c270d11f9c7109732ddfff9ecc49473a9d2 Mon Sep 17 00:00:00 2001 +From 803aeaea8d4b1f6f62bf208a9c826664af1cc24c Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Fri, 2 Oct 2020 00:03:12 +0200 Subject: [PATCH 09/26] cross compile darwin @@ -29,7 +29,7 @@ index b017b841311..f7821ae7f28 100644 try: import plistlib diff --git a/configure b/configure -index 30590a397f8..62fae1195fb 100755 +index 2088290f0ee..13fa7eb8101 100755 --- a/configure +++ b/configure @@ -4112,6 +4112,9 @@ then @@ -53,7 +53,7 @@ index 30590a397f8..62fae1195fb 100755 _host_ident= ;; diff --git a/configure.ac b/configure.ac -index 87c0ead45a6..5b0c8eea724 100644 +index aed14946731..fcc0e58963e 100644 --- a/configure.ac +++ b/configure.ac @@ -324,6 +324,9 @@ then diff --git a/recipe/patches/0010-Fix-TZPATH-on-windows.patch b/recipe/patches/0010-Fix-TZPATH-on-windows.patch index 7057173e..1133ef81 100644 --- a/recipe/patches/0010-Fix-TZPATH-on-windows.patch +++ b/recipe/patches/0010-Fix-TZPATH-on-windows.patch @@ -1,4 +1,4 @@ -From 47e52678a3fed79141b2a6e55764f9f4dbd57fb5 Mon Sep 17 00:00:00 2001 +From 44df125643cd6cc308950430410ea157becfbb30 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Wed, 7 Oct 2020 10:08:30 -0500 Subject: [PATCH 10/26] Fix TZPATH on windows diff --git a/recipe/patches/0011-Make-dyld-search-work-with-SYSTEM_VERSION_COMPAT-1.patch b/recipe/patches/0011-Make-dyld-search-work-with-SYSTEM_VERSION_COMPAT-1.patch index c5884906..0bd0357e 100644 --- a/recipe/patches/0011-Make-dyld-search-work-with-SYSTEM_VERSION_COMPAT-1.patch +++ b/recipe/patches/0011-Make-dyld-search-work-with-SYSTEM_VERSION_COMPAT-1.patch @@ -1,4 +1,4 @@ -From b8aa2c7193d4c6747703004a469a9c50ec1fa870 Mon Sep 17 00:00:00 2001 +From 865dd0bfac76b1e793d0a8d70e736c3c79e3d5f6 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Mon, 25 Jan 2021 03:28:08 -0600 Subject: [PATCH 11/26] Make dyld search work with SYSTEM_VERSION_COMPAT=1 diff --git a/recipe/patches/0012-Unvendor-bzip2.patch b/recipe/patches/0012-Unvendor-bzip2.patch index 7f76ab20..0c206183 100644 --- a/recipe/patches/0012-Unvendor-bzip2.patch +++ b/recipe/patches/0012-Unvendor-bzip2.patch @@ -1,4 +1,4 @@ -From 573f7e93e08ab0f6b589cd5e6e3164bf7bf11a62 Mon Sep 17 00:00:00 2001 +From 04122ddcb01d55991402257c11217b6b6cb4ff26 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Mon, 16 Aug 2021 02:56:27 -0700 Subject: [PATCH 12/26] Unvendor bzip2 diff --git a/recipe/patches/0013-Unvendor-libffi.patch b/recipe/patches/0013-Unvendor-libffi.patch index 8345c1cd..77ab1968 100644 --- a/recipe/patches/0013-Unvendor-libffi.patch +++ b/recipe/patches/0013-Unvendor-libffi.patch @@ -1,4 +1,4 @@ -From d8174073451f311fe02fe3ab9b86b61516503682 Mon Sep 17 00:00:00 2001 +From 0cf3e68100c1c4bb1bc4a1aee5e6d9b2682af821 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Mon, 16 Aug 2021 03:07:40 -0700 Subject: [PATCH 13/26] Unvendor libffi diff --git a/recipe/patches/0014-Unvendor-tcltk.patch b/recipe/patches/0014-Unvendor-tcltk.patch index 41026bfe..0c010367 100644 --- a/recipe/patches/0014-Unvendor-tcltk.patch +++ b/recipe/patches/0014-Unvendor-tcltk.patch @@ -1,4 +1,4 @@ -From fccbe2a0fb0b4254450505b0b5f924a52d4e261b Mon Sep 17 00:00:00 2001 +From 771b7e5d29f2dabe5c5af3544cd52d942969fc87 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Fri, 20 Aug 2021 10:23:51 -0700 Subject: [PATCH 14/26] Unvendor tcltk diff --git a/recipe/patches/0015-unvendor-xz.patch b/recipe/patches/0015-unvendor-xz.patch index 8aa90981..50f96bf5 100644 --- a/recipe/patches/0015-unvendor-xz.patch +++ b/recipe/patches/0015-unvendor-xz.patch @@ -1,4 +1,4 @@ -From a1403bff6fbd63835c52c1eb1306c4dc52ea786f Mon Sep 17 00:00:00 2001 +From 3f4fd834df73f0d1329f4978eaca3115d6421cea Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sat, 25 Sep 2021 10:07:05 -0700 Subject: [PATCH 15/26] unvendor xz diff --git a/recipe/patches/0016-unvendor-zlib.patch b/recipe/patches/0016-unvendor-zlib.patch index fb7372f7..fbba5345 100644 --- a/recipe/patches/0016-unvendor-zlib.patch +++ b/recipe/patches/0016-unvendor-zlib.patch @@ -1,4 +1,4 @@ -From c8298da150c2f58d697ccf8629bd6d8454207c15 Mon Sep 17 00:00:00 2001 +From ab500d12752b39f04c8aca04b6fe1249ae38ef51 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Wed, 29 Sep 2021 15:21:55 -0700 Subject: [PATCH 16/26] unvendor zlib diff --git a/recipe/patches/0017-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch b/recipe/patches/0017-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch index 11cf2472..64c6ba2f 100644 --- a/recipe/patches/0017-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch +++ b/recipe/patches/0017-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch @@ -1,4 +1,4 @@ -From 7b2a0d7a38d533553a82996d6707da289ed53525 Mon Sep 17 00:00:00 2001 +From 719981a07f9546b08648c1e80d7d42224dd6ed9a Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Wed, 16 Aug 2017 11:45:28 +0100 Subject: [PATCH 17/26] Do not pass -g to GCC when not Py_DEBUG @@ -10,7 +10,7 @@ This bloats our exe and our modules a lot. 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/configure b/configure -index 62fae1195fb..58a6040f872 100755 +index 13fa7eb8101..c47039af150 100755 --- a/configure +++ b/configure @@ -5796,9 +5796,9 @@ if test $ac_test_CFLAGS; then @@ -35,7 +35,7 @@ index 62fae1195fb..58a6040f872 100755 ;; *) diff --git a/configure.ac b/configure.ac -index 5b0c8eea724..fc6412b2a83 100644 +index fcc0e58963e..3969e38be04 100644 --- a/configure.ac +++ b/configure.ac @@ -2339,7 +2339,7 @@ then diff --git a/recipe/patches/0018-Unvendor-expat.patch b/recipe/patches/0018-Unvendor-expat.patch index 47d8499c..46e7f22f 100644 --- a/recipe/patches/0018-Unvendor-expat.patch +++ b/recipe/patches/0018-Unvendor-expat.patch @@ -1,4 +1,4 @@ -From 7731dd6164968061dc062b7fb1c91453071d6f46 Mon Sep 17 00:00:00 2001 +From bac6bfc09cf09d73895fa839d0464a9f60b9320d Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Wed, 29 Mar 2023 23:07:10 -0500 Subject: [PATCH 18/26] Unvendor expat diff --git a/recipe/patches/0019-Remove-unused-readelf.patch b/recipe/patches/0019-Remove-unused-readelf.patch index d85d2c61..d68a608f 100644 --- a/recipe/patches/0019-Remove-unused-readelf.patch +++ b/recipe/patches/0019-Remove-unused-readelf.patch @@ -1,4 +1,4 @@ -From 1b92eda27ab5c4041716ca7edd664e7722d003f3 Mon Sep 17 00:00:00 2001 +From 5f0b263a122f114cd65fec4310a3052e9151d512 Mon Sep 17 00:00:00 2001 From: Charles Bousseau Date: Thu, 25 May 2023 17:56:53 -0400 Subject: [PATCH 19/26] Remove unused readelf @@ -15,7 +15,7 @@ Drop unused build dependency on ``readelf``. 1 file changed, 1 deletion(-) diff --git a/Makefile.pre.in b/Makefile.pre.in -index da6d7c33156..1eed651e2fe 100644 +index f86d7363e09..997fdedffa1 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in @@ -38,7 +38,6 @@ CC= @CC@ diff --git a/recipe/patches/0020-Don-t-checksharedmods-if-cross-compiling.patch b/recipe/patches/0020-Don-t-checksharedmods-if-cross-compiling.patch index 376541d3..c6f1063e 100644 --- a/recipe/patches/0020-Don-t-checksharedmods-if-cross-compiling.patch +++ b/recipe/patches/0020-Don-t-checksharedmods-if-cross-compiling.patch @@ -1,4 +1,4 @@ -From e40f33bd5a53580742acae864fb95986171bb70a Mon Sep 17 00:00:00 2001 +From 73b753202af935b523b690a24a143d88b0ab5224 Mon Sep 17 00:00:00 2001 From: "Uwe L. Korn" Date: Fri, 1 Sep 2023 23:32:14 +0200 Subject: [PATCH 20/26] Don't checksharedmods if cross-compiling @@ -10,7 +10,7 @@ Subject: [PATCH 20/26] Don't checksharedmods if cross-compiling create mode 100755 if_runnable.sh diff --git a/Makefile.pre.in b/Makefile.pre.in -index 1eed651e2fe..94382a7ebe1 100644 +index 997fdedffa1..1ab701a52dd 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in @@ -1599,7 +1599,7 @@ sharedmods: $(SHAREDMODS) pybuilddir.txt diff --git a/recipe/patches/0021-Override-configure-LIBFFI.patch b/recipe/patches/0021-Override-configure-LIBFFI.patch index da0aa914..531e3dd0 100644 --- a/recipe/patches/0021-Override-configure-LIBFFI.patch +++ b/recipe/patches/0021-Override-configure-LIBFFI.patch @@ -1,4 +1,4 @@ -From 98d88de3ac347d1498505bb3b0a93bf40eb58584 Mon Sep 17 00:00:00 2001 +From 15dd45a639190a9307dc229b37bbb1a7c651897a Mon Sep 17 00:00:00 2001 From: "Uwe L. Korn" Date: Tue, 5 Sep 2023 21:51:31 +0200 Subject: [PATCH 21/26] Override configure LIBFFI @@ -8,7 +8,7 @@ Subject: [PATCH 21/26] Override configure LIBFFI 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure -index 58a6040f872..d3af49f5e52 100755 +index c47039af150..56788a4a9b9 100755 --- a/configure +++ b/configure @@ -15358,7 +15358,7 @@ if test "x$ac_cv_lib_ffi_ffi_call" = xyes diff --git a/recipe/patches/0022-Unvendor-libmpdec.patch b/recipe/patches/0022-Unvendor-libmpdec.patch index 7d8df6c9..e28b2b2d 100644 --- a/recipe/patches/0022-Unvendor-libmpdec.patch +++ b/recipe/patches/0022-Unvendor-libmpdec.patch @@ -1,4 +1,4 @@ -From 64f79fdc06f2a4bc0669d01bc15ec48828d8aa04 Mon Sep 17 00:00:00 2001 +From eb1432807cab49ff047fce3cde700f7488379dd6 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Fri, 16 Aug 2024 21:34:43 -0500 Subject: [PATCH 22/26] Unvendor libmpdec diff --git a/recipe/patches/0023-Brand-conda-forge.patch b/recipe/patches/0023-Brand-conda-forge.patch index aadb97fa9..99eda784 100644 --- a/recipe/patches/0023-Brand-conda-forge.patch +++ b/recipe/patches/0023-Brand-conda-forge.patch @@ -1,4 +1,4 @@ -From 0decb9be8dd5fa946a32f2b4131cf5d20207e755 Mon Sep 17 00:00:00 2001 +From 5076150e13869eef46ae60f3d1b242b417688461 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Wed, 28 Aug 2024 11:12:22 -0500 Subject: [PATCH 23/26] Brand conda-forge diff --git a/recipe/patches/0024-Do-not-define-pid_t-as-it-might-conflict-with-the-ac.patch b/recipe/patches/0024-Do-not-define-pid_t-as-it-might-conflict-with-the-ac.patch index 95f93d65..bf081a10 100644 --- a/recipe/patches/0024-Do-not-define-pid_t-as-it-might-conflict-with-the-ac.patch +++ b/recipe/patches/0024-Do-not-define-pid_t-as-it-might-conflict-with-the-ac.patch @@ -1,4 +1,4 @@ -From ffbe5dd381d0e1c1da006572b6da4cb99f36c99e Mon Sep 17 00:00:00 2001 +From 68b6f1e2b050062c5541c5064dc12f4c38b68124 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sun, 12 Jan 2025 10:37:29 +0530 Subject: [PATCH 24/26] Do not define pid_t as it might conflict with the @@ -30,7 +30,7 @@ index 6313abf5485..bc8169e2f68 100644 module _testcapi [clinic start generated code]*/ diff --git a/Modules/_testcapimodule.c b/Modules/_testcapimodule.c -index 567966ca558..d4526ed915a 100644 +index b5aba8d64ac..5a419ea0f8d 100644 --- a/Modules/_testcapimodule.c +++ b/Modules/_testcapimodule.c @@ -23,6 +23,10 @@ @@ -45,7 +45,7 @@ index 567966ca558..d4526ed915a 100644 # error "The public headers should not include , see gh-48924" #endif diff --git a/Modules/_testlimitedcapi/long.c b/Modules/_testlimitedcapi/long.c -index 34bc7331da9..abae4b19bf0 100644 +index 99b9e96760d..932fef0497f 100644 --- a/Modules/_testlimitedcapi/long.c +++ b/Modules/_testlimitedcapi/long.c @@ -8,6 +8,10 @@ @@ -60,7 +60,7 @@ index 34bc7331da9..abae4b19bf0 100644 module _testlimitedcapi [clinic start generated code]*/ diff --git a/Modules/clinic/posixmodule.c.h b/Modules/clinic/posixmodule.c.h -index 1c7a860e1ec..64bdbdf23db 100644 +index 094580e7c23..02d74ec937d 100644 --- a/Modules/clinic/posixmodule.c.h +++ b/Modules/clinic/posixmodule.c.h @@ -10,6 +10,10 @@ preserve @@ -75,7 +75,7 @@ index 1c7a860e1ec..64bdbdf23db 100644 "stat($module, /, path, *, dir_fd=None, follow_symlinks=True)\n" "--\n" diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c -index 31b2d28200c..cc7e40c0283 100644 +index 69e28a1ff95..ca4d58dfd63 100644 --- a/Modules/posixmodule.c +++ b/Modules/posixmodule.c @@ -219,6 +219,7 @@ diff --git a/recipe/patches/0025-Unvendor-zstd.patch b/recipe/patches/0025-Unvendor-zstd.patch index 84d2be63..f3f0a4a4 100644 --- a/recipe/patches/0025-Unvendor-zstd.patch +++ b/recipe/patches/0025-Unvendor-zstd.patch @@ -1,4 +1,4 @@ -From 5a981c1f933f53e35e2e9cddb24af4b7f5162524 Mon Sep 17 00:00:00 2001 +From 70e96283f139a845467ecde9fe758dc84b1a252a Mon Sep 17 00:00:00 2001 From: "Uwe L. Korn" Date: Tue, 22 Jul 2025 18:07:54 +0200 Subject: [PATCH 25/26] Unvendor zstd diff --git a/recipe/patches/0026-Set-Py_GIL_DISABLED-in-windows-to-match-unix.patch b/recipe/patches/0026-Set-Py_GIL_DISABLED-in-windows-to-match-unix.patch index bb61c74f..99e33ac3 100644 --- a/recipe/patches/0026-Set-Py_GIL_DISABLED-in-windows-to-match-unix.patch +++ b/recipe/patches/0026-Set-Py_GIL_DISABLED-in-windows-to-match-unix.patch @@ -1,4 +1,4 @@ -From a1edec6cc57778800d48eacd98bbb029b31c3b99 Mon Sep 17 00:00:00 2001 +From 1fa1e88b901278be305383651f07b1ac605e61af Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Tue, 2 Dec 2025 09:46:56 -0800 Subject: [PATCH 26/26] Set Py_GIL_DISABLED in windows to match unix diff --git a/recipe/run_test.py b/recipe/run_test.py index d53c4a38..bbe13e46 100644 --- a/recipe/run_test.py +++ b/recipe/run_test.py @@ -107,3 +107,11 @@ # See https://github.com/conda-forge/python-feedstock/issues/718 for context: assert sys.hash_info.algorithm.startswith("siphash") + +# xref https://github.com/conda-forge/openssl-feedstock/issues/237 +import ssl +print("openssl:", ssl.OPENSSL_VERSION) +pem = ssl.get_server_certificate(("pypi.org", 443)) +der = ssl.PEM_cert_to_DER_cert(pem) +ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT) +ctx.load_verify_locations(cadata=der)