-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Template CI/CD action to track compatibility with Cpython as per GHI 5974 (title is WIP) #6176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
reactive-firewall
wants to merge
62
commits into
RustPython:main
Choose a base branch
from
reactive-firewall:main
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from 60 commits
Commits
Show all changes
62 commits
Select commit
Hold shift + click to select a range
a67bd8a
Prototyping 5974
reactive-firewall bc3d741
Prototype test of Check_Tests.yml
reactive-firewall 579df4a
Update Check_Tests.yml
reactive-firewall 3b0b622
Update Check_Tests.yml
reactive-firewall 8fb83bb
Update Check_Tests.yml
reactive-firewall 370eeb9
Tweaked Check_Tests.yml
reactive-firewall 7032a3c
Update Check_Tests.yml
reactive-firewall c984045
DEBUG for Check_Tests.yml
reactive-firewall 42e6bd1
DEBUG Check_Tests.yml
reactive-firewall da5c6b6
DEBUG Check_Tests.yml builds
reactive-firewall 7b84e63
Update Check_Tests.yml
reactive-firewall e8dd40a
Fixup Check_Tests.yml more
reactive-firewall e4ea145
Update envs for OS in Check_Tests.yml
reactive-firewall 62b2159
First just-integrate Cpython into Rustpython Automation test for Rust…
reactive-firewall 16908ce
Second-Attempt for GHI RustPython/RustPython#5974
reactive-firewall 7650576
Remove ulimit and re-test
reactive-firewall bcf6261
Update Check_Tests.yml to attempt auto-fix via fix_test.py
reactive-firewall ec878b6
STYLE fixes for Check_Tests.yml
reactive-firewall 7a1122c
More Tweaking of Check_Tests.yml
reactive-firewall 7b14fb8
Smarter filtering for direct invocation in Check_Tests.yml
reactive-firewall f1e1e1b
regression fix for Check_Tests.yml and re-test
reactive-firewall 14b67ad
WIP - UNSTABLE
reactive-firewall d638f06
Update Check_Tests.yml with unittest logic
reactive-firewall 5706652
Update Check_Tests.yml with shorter timeout limit
reactive-firewall ab1ab43
DEBUG Check_Tests.yml
reactive-firewall 5e12149
WIP DEBUG STEP
reactive-firewall c1f6dfd
Expand to recurse Lib/test (WIP)
reactive-firewall 3e65b53
Initial Refactor for CI-5974
reactive-firewall d1a9d08
Re:re: Fixup for overlooked regression from initial refactor
reactive-firewall cad55c6
:see_no_evil: Oops! No globbing sparse checkouts, must enumerate
reactive-firewall c5b556e
DEBUG sparse checkout for actions
reactive-firewall 464eedb
Minor Regression fix for CI inputs
reactive-firewall d0469bd
DEBUG Refactor a bit
reactive-firewall 18ec6ed
DEBUG integration action a bit more
reactive-firewall c3f5651
Refactored Smoke-testing experiment into re-useable action
reactive-firewall 32583f5
Fix typo regression.
reactive-firewall e4dd8ce
:rocket: Prototype
reactive-firewall f2ab013
:see_no_evil: More minor fixes for CI actions
reactive-firewall 708a78a
Oops! forgot the expansion - retry post-proc summary
reactive-firewall 9e7a8ec
Improved the final output slightly
reactive-firewall 7c8894a
:sparkle: Improved post-proc some more.
reactive-firewall 101b653
Add quotes?
reactive-firewall ebd23cf
More cleanup of new actions
reactive-firewall 918fb9d
Small improvements to the new actions reporting logic WIP
reactive-firewall 7d3dc3d
Revert triggers for now
reactive-firewall 63c6f61
Issue with chickens and eggs and the order of things.
reactive-firewall 6a2353c
More minor fixes
reactive-firewall d36c8ca
Oops Missed one.
reactive-firewall 6534d1c
[DEMO] Protoytpe from GHI #5974 with rpau from PR #6089
reactive-firewall aa209d4
[DEBUG] Opps misunderstood location of tools dir.
reactive-firewall cf5e371
[DEBUG] Attempt to -c invoke rpau tool with modified import (WIP PR #…
reactive-firewall cd3dc0a
[DEBUG] possible workaround for braindead windows runners
reactive-firewall 42254c7
[DEBUG] Minor Regression fix for double entries. Oops.
reactive-firewall 8b8398b
[STYLE] Cleaning up the report for CI runs a bit.
reactive-firewall e79c13b
[DEBUG] Adjust output path to upload at end
reactive-firewall b211032
[PATCH] workaround for elusive patched files
reactive-firewall d65b890
Testing based on examples from PR RustPython/RustPython#6089
reactive-firewall e20f6c5
Oops! forgot to mkdir in setup phase re-try test.
reactive-firewall 3dd549f
Test for new Lib_updater.py script in integration phase (for Lib/test…
reactive-firewall 64728df
[PATCH] Template Regression check in CI/CD
reactive-firewall b87cb8a
Apply suggestions from code review with AI assistant
reactive-firewall 1960425
[PATCH] Cleanup from automated review in PR #6176
reactive-firewall File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,174 @@ | ||
| --- | ||
| name: 'Checkout CPython' | ||
| description: 'checks-out the given CPython version' | ||
| author: 'Mr. Walls' | ||
| branding: | ||
| icon: 'download-cloud' | ||
| color: 'blue' | ||
| inputs: | ||
| override-repository: | ||
| description: | | ||
| The GitHub repository to clone CPython from. When running this action on github.com, | ||
| the default value is sufficient. Useful for Forks. | ||
| required: true | ||
| default: ${{ github.server_url == 'https://github.com' && github.repository || 'python/cpython' }} | ||
| override-rustpython-path: | ||
| description: | | ||
| override value for path to the Python Lib. The default is to use the value of the environment | ||
| variable 'RUSTPYTHONPATH'. Most users will find the default 'Lib' sufficient. | ||
| required: true | ||
| default: ${{ github.server_url == 'https://github.com' && github.repository || 'Lib' }} | ||
| override-path: | ||
| description: | | ||
| Path to setup. When running this action on github.com, the default value | ||
| is sufficient. MUST be a path to a directory named 'cpython'. | ||
| required: true | ||
| default: ${{ github.server_url == 'https://github.com' && github.workspace || 'cpython' }} | ||
| override-cpython-lib-path: | ||
| description: | | ||
| override value for path to the CPython Reference Lib. The default is to use the value of the | ||
| environment variable 'PYTHONPLATLIBDIR'. Most users will find the default 'Lib' sufficient. | ||
| See https://docs.python.org/3/using/cmdline.html#envvar-PYTHONPLATLIBDIR for more. | ||
| required: true | ||
| default: ${{ github.server_url == 'https://github.com' && github.repository || 'Lib' }} | ||
| match: | ||
| description: | | ||
| Glob-style pattern of files or directories to match and integrate. | ||
| Only works with git tracked files. | ||
| required: true | ||
| type: string | ||
| default: 'Lib/test/*.py Lib/test/**/*.py' | ||
| ignore: | ||
| description: | | ||
| List of Glob-style patterns of files or directories to ignore. | ||
| Only works with git tracked files. | ||
| required: false | ||
| type: string | ||
| github-token: | ||
| description: | | ||
| The token used to authenticate when fetching RustPython commits from | ||
| https://github.com/RustPython/RustPython.git. When running this action on github.com, | ||
| the default value is sufficient. When running on GHES, you can pass a personal access | ||
| token for github.com if you are experiencing rate limiting. | ||
| default: ${{ github.server_url == 'https://github.com' && github.token || '' }} | ||
| required: true | ||
| python-version: | ||
| description: | | ||
| The Cpython version (e.g., any valid release or tag, 3.11, 3.12, 3.13) to override setup. | ||
| The default is to use the value of the environment variable 'PYTHON_VERSION'. | ||
| default: '3.13' | ||
| required: true | ||
| outputs: | ||
| branch-name: | ||
| description: "The name of the branch that was checked-out." | ||
| value: ${{ steps.output_branch_name.outputs.branch-name || '' }} | ||
| sha: | ||
| description: "The SHA of the commit checked-out." | ||
| value: ${{ steps.output_sha.outputs.sha || 'HEAD' }} | ||
| files: | ||
| description: "The downloaded artifact-files." | ||
| value: ${{ steps.output_cpython_files.outputs.files }} | ||
|
|
||
| runs: | ||
| using: composite | ||
| steps: | ||
| - name: "Setup Python" | ||
| id: output_python | ||
| env: | ||
| PYTHON_VERSION_INPUT: ${{ inputs.python-version }} | ||
| shell: bash | ||
| run: | | ||
| if [[ -n $PYTHON_VERSION_INPUT ]]; then | ||
| printf "python-version=%s\n" "${PYTHON_VERSION_INPUT}" >> "$GITHUB_OUTPUT" | ||
| PYTHON_VERSION=${PYTHON_VERSION_INPUT} | ||
| else | ||
| printf "python-version=%s\n" "${PYTHON_VERSION}" >> "$GITHUB_OUTPUT" | ||
| fi | ||
| printf "%s\n" "PYTHON_VERSION=${PYTHON_VERSION}" >> "$GITHUB_ENV" | ||
| - name: Fetch Reference Cpython ${{ matrix.python-version }} on ${{ matrix.os }} | ||
| id: cpython | ||
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | ||
| with: | ||
| persist-credentials: false | ||
| path: ${{ inputs.override-path }} | ||
| fetch-tags: true | ||
| sparse-checkout: | | ||
| ${{ inputs.override-cpython-lib-path }} | ||
| ref: ${{ steps.output_python.outputs.python-version }} | ||
| repository: ${{ inputs.override-repository }} | ||
| # fixed settings | ||
| fetch-depth: 0 | ||
| sparse-checkout-cone-mode: false | ||
| submodules: true | ||
| token: ${{ inputs.github-token }} | ||
| - id: store_old_path | ||
| if: ${{ !cancelled() }} | ||
| shell: bash | ||
| run: | | ||
| cd ${PWD:-.} ; | ||
| export OLD_PWD=$(pwd) ; # only local use for bootstrap | ||
| printf "initial-path=%s\n" "${OLD_PWD}" >> "$GITHUB_OUTPUT" | ||
| - id: output_branch_name | ||
| if: ${{ !cancelled() }} | ||
| shell: bash | ||
| run: | | ||
| cd ${{ inputs.override-path }} || exit 14 ; | ||
| printf "branch-name=%s\n" $(git name-rev --name-only HEAD | cut -d~ -f1-1) >> "$GITHUB_OUTPUT" | ||
| cd ${{ steps.store_old_path.outputs.initial-path }} || exit 15 ; | ||
| - id: output_sha | ||
| shell: bash | ||
| run: | | ||
| cd ${{ inputs.override-path }} || exit 14 ; | ||
| printf "sha=%s\n" $(git log -1 --format=%H) >> "$GITHUB_OUTPUT" | ||
| cd ${{ steps.store_old_path.outputs.initial-path }} || exit 15 ; | ||
| - name: Configure Ignored Reference Lib Files | ||
| id: refignorefiles | ||
| shell: bash | ||
| env: | ||
| GIT_IGNORE_PATTERN: ${{ inputs.ignore || '' }} | ||
| run: | | ||
| # TODO: include work from RustPython/scripts/notes.txt | ||
| cd ${{ inputs.override-path }} || exit 14 ; | ||
| if [[ -w ".git/info/exclude" ]] ; then | ||
| printf "%s\n" ${GIT_IGNORE_PATTERN:-} >>".git/info/exclude" || : ; | ||
| else | ||
| printf "::debug::%s\n" "Could not find .git/info/exclude" ; | ||
| printf "%s\n" ${GIT_IGNORE_PATTERN:-} >>".gitignore" || : ; | ||
| fi ; | ||
| cd ${{ steps.store_old_path.outputs.initial-path }} || exit 15 ; | ||
| if: ${{ success() }} | ||
| - name: Enumerate Reference Lib Files | ||
| id: output_cpython_files | ||
| shell: bash | ||
| env: | ||
| TEST_MATCH_PATTERN: ${{ inputs.match || '' }} | ||
| run: | | ||
| cd ${{ inputs.override-path }} || exit 14 ; | ||
| FILES=$(git ls-files --exclude-standard -- ${{ env.TEST_MATCH_PATTERN }} ) | ||
| if [ -z "$FILES" ]; then | ||
| printf "%s\n" "::warning file=.github/actions/:: No ${{ inputs.override-cpython-lib-path }} Reference files found for Cpython ${{ inputs.python-version }} on ${{ runner.os }}." ; | ||
| printf "%s\n" "files=" >> "$GITHUB_OUTPUT" | ||
| else | ||
| printf "%s\n" "Reference files found:" | ||
| printf "%s\n" "$FILES" | ||
| # Replace line breaks with commas for GitHub Action Output | ||
| FILES="${FILES//$'\n'/ }" | ||
| printf "%s\n" "files=$FILES" >> "$GITHUB_OUTPUT" | ||
| fi | ||
| cd ${{ steps.store_old_path.outputs.initial-path }} || exit 15 ; | ||
| if: ${{ success() }} | ||
| - name: "License" | ||
| id: show_cpython_license | ||
| shell: bash | ||
| if: ${{ !cancelled() }} | ||
| run: | | ||
| cd ${{ inputs.override-path }} || exit 14 ; | ||
| if [[ -r LICENSE ]] ; then | ||
| printf "\n\n" | ||
| cat <LICENSE ; | ||
| printf "\n\n" | ||
| else | ||
| printf "%s\n" "::warning title=UNLICENSED:: This is an UNLICENSED Build for Cpython ${{ inputs.python-version }} on ${{ runner.os }}" | ||
| fi | ||
| cd ${{ steps.store_old_path.outputs.initial-path }} || exit 15 ; | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,130 @@ | ||
| --- | ||
| name: 'Checkout and Build RustPython' | ||
| description: 'checks-out the given Rust-Python commit and builds RustPython' | ||
| author: 'Mr. Walls' | ||
| branding: | ||
| icon: 'download-cloud' | ||
| color: 'yellow' | ||
| inputs: | ||
| override-ref: | ||
| description: | | ||
| The commit or git ref to checkout and build for. When running this action on github.com, | ||
| the default value is sufficient. | ||
| required: true | ||
| default: ${{ github.server_url == 'https://github.com' && github.sha || 'main' }} | ||
| override-repository: | ||
| description: | | ||
| The GitHub repository to clone RustPython from. When running this action on github.com, | ||
| the default value is sufficient. Useful for Forks. | ||
| required: true | ||
| default: ${{ github.server_url == 'https://github.com' && github.repository || 'RustPython/RustPython' }} | ||
| override-rustpython-path: | ||
| description: | | ||
| override value for path to the Python Lib. The default is to use the value of the environment | ||
| variable 'RUSTPYTHONPATH'. Most users will find the default 'Lib' sufficient. | ||
| required: true | ||
| default: ${{ github.server_url == 'https://github.com' && github.repository || 'Lib' }} | ||
| override-path: | ||
| description: | | ||
| Path to setup. When running this action on github.com, the default value | ||
| is sufficient. MUST be a path to a directory named 'rustpython'. | ||
| required: true | ||
| default: ${{ github.server_url == 'https://github.com' && github.workspace || 'rustpython' }} | ||
reactive-firewall marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| github-token: | ||
reactive-firewall marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| description: | | ||
| The token used to authenticate when fetching RustPython commits from | ||
| https://github.com/RustPython/RustPython.git. When running this action on github.com, | ||
| the default value is sufficient. When running on GHES, you can pass a personal access | ||
| token for github.com if you are experiencing rate limiting. | ||
| default: ${{ github.server_url == 'https://github.com' && github.token || '' }} | ||
| required: true | ||
| outputs: | ||
| branch-name: | ||
| description: "The name of the branch that was checked-out." | ||
| value: ${{ steps.output_branch_name.outputs.branch-name || '' }} | ||
| sha: | ||
| description: "The SHA of the commit checked-out." | ||
| value: ${{ steps.output_sha.outputs.sha || 'HEAD' }} | ||
| rustpython-version: | ||
| description: "The python version that was used in the run." | ||
| value: '0.4' # TODO: fix this | ||
| rustpython-lib-path: | ||
| description: "The python version that was used in the run." | ||
| value: ${{ steps.output_rpython_path.output.rustpython-lib-path }} | ||
reactive-firewall marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| runs: | ||
| using: composite | ||
| steps: | ||
| - name: Checkout repository | ||
| id: rpython | ||
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | ||
| with: | ||
| path: ${{ inputs.override-path }} | ||
| persist-credentials: false | ||
| ref: ${{ inputs.override-ref }} | ||
| repository: ${{ inputs.override-repository }} | ||
| # fixed settings | ||
| fetch-depth: 0 | ||
| sparse-checkout-cone-mode: false | ||
| submodules: true | ||
| token: ${{ inputs.github-token }} | ||
| - id: store_old_path | ||
| if: ${{ !cancelled() }} | ||
| shell: bash | ||
| run: | | ||
| cd ${PWD:-.} ; | ||
| export OLD_PWD=$(pwd) ; # only local use for bootstrap | ||
| printf "initial-path=%s\n" "${OLD_PWD}" >> "$GITHUB_OUTPUT" ; | ||
| if [[ "$RUNNER_DEBUG" == "true" ]] || [[ "$ACTIONS_STEP_DEBUG" == "true" ]]; then | ||
| printf "::debug::Return directory now set to '%s'\n" "${OLD_PWD}" ; | ||
| printf "::debug::Working directory is set to '%s'\n" '${{ inputs.override-path }}' ; | ||
| fi ; | ||
| - id: output_branch_name | ||
| if: ${{ !cancelled() }} | ||
| shell: bash | ||
| run: | | ||
| cd ${{ inputs.override-path }} || exit 13 ; | ||
| printf "branch-name=%s\n" $(git name-rev --name-only HEAD | cut -d~ -f1-1) >> "$GITHUB_OUTPUT" | ||
| cd ${{ steps.store_old_path.outputs.initial-path }} || exit 15 ; | ||
| - id: output_sha | ||
| shell: bash | ||
| run: | | ||
| cd ${{ inputs.override-path }} || exit 13 ; | ||
| printf "sha=%s\n" $(git log -1 --format=%H) >> "$GITHUB_OUTPUT" | ||
| cd ${{ steps.store_old_path.outputs.initial-path }} || exit 15 ; | ||
| - name: "Setup Cargo" | ||
| id: output_cargo_args | ||
| shell: bash | ||
| run: | | ||
| if [[ -n $CARGO_ARGS ]]; then | ||
| if [[ "$RUNNER_DEBUG" == "true" ]] || [[ "$ACTIONS_STEP_DEBUG" == "true" ]]; then printf "::debug::CARGO_ARGS already set to '%s'\n" "${CARGO_ARGS}" ; fi ; | ||
| # e.g., CARGO_ARGS=${CARGO_ARGS} | ||
| else | ||
| CARGO_ARGS="--release" ; | ||
| if [[ "$RUNNER_DEBUG" == "true" ]] || [[ "$ACTIONS_STEP_DEBUG" == "true" ]]; then printf "::debug::CARGO_ARGS initialized to '%s'\n" "${CARGO_ARGS}" ; fi ; | ||
| fi ; | ||
| printf "%s\n" "CARGO_ARGS=${CARGO_ARGS}" >> "$GITHUB_ENV" ; | ||
| - name: Pre-Test Build check | ||
| id: build_rpython | ||
| shell: bash | ||
| env: | ||
| OS: ${{ runner.os }} | ||
| if: ${{ !cancelled() }} | ||
| run: | | ||
| cd ${{ inputs.override-path }} || exit 13 ; | ||
| printf "::group::%s\n" "Cargo" ; | ||
| if [[ "$RUNNER_DEBUG" == "true" ]] || [[ "$ACTIONS_STEP_DEBUG" == "true" ]]; then printf "::debug::Now Building '%s'\n" "RustPython" ; fi ; | ||
| # Execute the testing command in a subshell | ||
| ( | ||
| RUSTPYTHONPATH=${{ inputs.override-rustpython-path }} cargo run $CARGO_ARGS -- --version || printf "::error title='build failure':: Could not pass build step for version check on ${OS}.\n" ; | ||
| ) ; | ||
| printf "::endgroup::%s\n" ; | ||
| cd ${{ steps.store_old_path.outputs.initial-path }} || exit 15 ; | ||
| - id: output_rpython_path | ||
| shell: bash | ||
| run: | | ||
| cd ${{ inputs.override-path }} || exit 13 ; # in case it is relative | ||
| cd ${{ inputs.override-rustpython-path }} || exit 13 ; | ||
| printf "RUSTPYTHONPATH=%s\n" $(pwd) >> "$GITHUB_ENV" ; | ||
| printf "rustpython-lib-path=%s\n" $(pwd) >> "$GITHUB_OUTPUT" ; | ||
| cd ${{ steps.store_old_path.outputs.initial-path }} || exit 15 ; | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,82 @@ | ||
| --- | ||
| name: 'Integrate Reference Implementation' | ||
| description: 'Copy Reference Implementation' | ||
| author: 'Mr. Walls' | ||
| branding: | ||
| icon: 'copy' | ||
| color: 'purple' | ||
| inputs: | ||
| into-path: | ||
| description: | | ||
| Path to Destination. Default is 'rustpython' | ||
| required: true | ||
| default: 'rustpython' | ||
| from-path: | ||
| description: | | ||
| Path to source. Default is 'cpython' | ||
| required: true | ||
| default: 'cpython' | ||
| files: | ||
| description: | | ||
| List of paths to copy from source to destination. Default is 'Lib/**/*.py' | ||
| required: true | ||
| default: 'Lib/**/*.py' | ||
| python-version: | ||
| description: | | ||
| The Cpython version (e.g., any valid release or tag, 3.11, 3.12, 3.13) to override setup. | ||
| The default is to use the value of the environment variable 'PYTHON_VERSION'. | ||
| default: '3.13' | ||
| required: true | ||
|
|
||
| # TODO: add verification steps | ||
|
|
||
| runs: | ||
| using: composite | ||
| steps: | ||
| - id: output_python | ||
| env: | ||
| PYTHON_VERSION_INPUT: ${{ inputs.python-version }} | ||
| name: "Detect Python" | ||
| if: ${{ inputs.files != '' }} | ||
| shell: bash | ||
| run: | | ||
| # check the python version | ||
| if [[ -n $PYTHON_VERSION_INPUT ]]; then | ||
| printf "python-version=%s\n" "${PYTHON_VERSION_INPUT}" >> "$GITHUB_OUTPUT" | ||
| PYTHON_VERSION=${PYTHON_VERSION_INPUT} | ||
| else | ||
| printf "python-version=%s\n" "${PYTHON_VERSION}" >> "$GITHUB_OUTPUT" | ||
| fi | ||
| printf "%s\n" "PYTHON_VERSION=${PYTHON_VERSION}" >> "$GITHUB_ENV" | ||
| if [[ "$RUNNER_DEBUG" == "true" ]] || [[ "$ACTIONS_STEP_DEBUG" == "true" ]]; then printf "::debug::Targeting Cpython %s.\n" "${PYTHON_VERSION}" ; fi ; | ||
| - id: setup_mkdir_option | ||
| if: ${{ !cancelled() }} | ||
| shell: bash | ||
| run: | | ||
| # set mkdir options per platform | ||
| if [[ ${{ runner.os }} != 'Windows' ]] ; then | ||
| printf "mkdir-args=%s\n" "-v -p -m 751" >> "$GITHUB_OUTPUT" | ||
| printf "MKDIR_ARGS=%s\n" "-v -p -m 751" >> "$GITHUB_ENV" | ||
| else | ||
| printf "mkdir-args=%s\n" "-v -p" >> "$GITHUB_OUTPUT" | ||
| printf "MKDIR_ARGS=%s\n" "-v -p" >> "$GITHUB_ENV" | ||
| fi | ||
| - name: "Integrate Cpython Test files" | ||
| id: merge_theirs | ||
| shell: bash | ||
| if: ${{ !cancelled() && inputs.files != '' }} | ||
| env: | ||
| INPUT_FILES: ${{ inputs.files }} | ||
| run: | | ||
| printf "::group::%s\n" "Copy Reference Implementation" ; | ||
| for reference_file in ${INPUT_FILES}; do | ||
| [[ -d $(dirname ${{ inputs.into-path }}/"${reference_file}" ) ]] || mkdir $MKDIR_ARGS $(dirname ${{ inputs.into-path }}/"${reference_file}" ) ; | ||
| if [[ "$reference_file" == Lib/test/* ]] ; then | ||
| # update patches with lib_updater tool from #6089 | ||
| ${{ inputs.into-path }}/scripts/lib_updater.py --from ${{ inputs.into-path }}/"${reference_file}" --to ${{ inputs.from-path }}/"${reference_file}" -o ${{ inputs.into-path }}/"${reference_file}" || \ | ||
| printf "::warning file='%s',title='integration failure':: Could not integrate file for Cpython %s on %s.\n" "${reference_file}" '${PYTHON_VERSION}' '${{ runner.os }}' ; | ||
| else | ||
| cp -vf ${{ inputs.from-path }}/"${reference_file}" ${{ inputs.into-path }}/"${reference_file}" || printf "::warning file='%s',title='integration failure':: Could not integrate file for Cpython %s on %s.\n" "${reference_file}" '${PYTHON_VERSION}' '${{ runner.os }}' ; | ||
| fi | ||
| done ; | ||
| printf "\n::endgroup::\n\n" ; |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.