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
10 changes: 10 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,14 @@ jobs:
if: needs.build-context.outputs.run-wasi == 'true'
uses: ./.github/workflows/reusable-wasi.yml

build-ubuntu-installed:
name: 'Ubuntu (installed)'
needs: build-context
if: needs.build-context.outputs.run-ubuntu == 'true'
uses: ./.github/workflows/reusable-install.yml
with:
os: ubuntu-24.04-arm

test-hypothesis:
name: "Hypothesis tests on Ubuntu"
runs-on: ubuntu-24.04
Expand Down Expand Up @@ -670,6 +678,7 @@ jobs:
- build-ios
- build-emscripten
- build-wasi
- build-ubuntu-installed
- test-hypothesis
- build-asan
- build-san
Expand Down Expand Up @@ -717,6 +726,7 @@ jobs:
&& '
build-ubuntu,
build-ubuntu-ssltests,
build-ubuntu-installed,
test-hypothesis,
build-asan,
build-san,
Expand Down
51 changes: 51 additions & 0 deletions .github/workflows/reusable-install.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Reusable Ubuntu (Installed)

on:
workflow_call:
inputs:
os:
description: OS to run the job
required: true
type: string

permissions:
contents: read

env:
FORCE_COLOR: 1

jobs:
build-install-reusable:
name: build, install and test (${{ inputs.os }})
runs-on: ${{ inputs.os }}
timeout-minutes: 60
env:
PYTHONSTRICTEXTENSIONBUILD: 1
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Runner image version
run: echo "IMAGE_OS_VERSION=${ImageOS}-${ImageVersion}" >> "$GITHUB_ENV"
- name: Register gcc problem matcher
run: echo "::add-matcher::.github/problem-matchers/gcc.json"
- name: Set install dir
run:
echo "INSTALL_DIR=$(realpath "${GITHUB_WORKSPACE}/../installed-python")" >> "$GITHUB_ENV"
- name: Install dependencies
run: sudo ./.github/workflows/posix-deps-apt.sh
- name: Configure CPython
run: ./configure --config-cache --with-pydebug --prefix="$INSTALL_DIR"
- name: Build CPython
run: make -j
- name: Install CPython
run: make install
- name: Set installed interpreter
run: |
ldversion=$(./python -c 'import sysconfig; print(sysconfig.get_config_var("LDVERSION"))')

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
ldversion=$(./python -c 'import sysconfig; print(sysconfig.get_config_var("LDVERSION"))')
ldversion="$(./python -c 'import sysconfig; print(sysconfig.get_config_var("LDVERSION"))')"

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Bash doesn’t split words on the RHS of an assignment. See this discussion for more information.

echo "INSTALLED_PYTHON=${INSTALL_DIR}/bin/python${ldversion}" >> "$GITHUB_ENV"
- name: Display build info
run: |
"$INSTALLED_PYTHON" -m test.pythoninfo
- name: Test the installed Python
run: xvfb-run "$INSTALLED_PYTHON" -m test -j0 --fast-ci --timeout=900
Loading