Skip to content
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

Prep minor release to support Python 3.8 and above versions #54

Merged
merged 137 commits into from
Sep 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
137 commits
Select commit Hold shift + click to select a range
e62bb89
Release support for Python 3.8 and above versions
amruthvvkp Sep 8, 2023
1229cae
Added requirements.txt file generated by pre-commit
amruthvvkp Sep 8, 2023
f638057
Minor upgrade to the existing GitHub actions.
amruthvvkp Sep 8, 2023
9ea227e
Release support for Python 3.8 and above versions
amruthvvkp Sep 8, 2023
5217415
Cleaned up pre-commit configuration
amruthvvkp Sep 8, 2023
902fe47
Updated GitHub actions for testing and publishing
amruthvvkp Sep 8, 2023
5a3a072
Updated GitHub actions dependency versions
amruthvvkp Sep 8, 2023
268c415
Updated Publish actions to upgrade version and publish.
amruthvvkp Sep 8, 2023
9cf1e87
Updated GitHub actions to smartly use requirements.txt for 3.7 else u…
amruthvvkp Sep 8, 2023
9d19770
Updated PR checks to run on various event changes
amruthvvkp Sep 8, 2023
4bf8d7e
Fixed "Error: Unhandled error: ReferenceError: fs is not defined" on …
amruthvvkp Sep 8, 2023
fb46c89
Minor fixes to resolve GitHub actions failures
amruthvvkp Sep 8, 2023
8e6ac90
Fixed pre-commit unavailable on Python 3.11
amruthvvkp Sep 8, 2023
afa5408
Modified GitHub actions to improve comments on PR
amruthvvkp Sep 8, 2023
2bf21a7
Fixed Author identity unknown failure on GitHub actions
amruthvvkp Sep 8, 2023
27cd6bf
Added Test applications for Pytest tests in GitHub actions
amruthvvkp Sep 8, 2023
d0fa03d
Updated GitHub actions
amruthvvkp Sep 8, 2023
e92b6fc
Updated building of test apps phase to use Ubuntu instead of Windows
amruthvvkp Sep 8, 2023
8e280e0
Added installation of PS before running build script
amruthvvkp Sep 8, 2023
5eea14e
Updated GitHub actions to use native Poetry upload action step
amruthvvkp Sep 8, 2023
a6ae740
Minor fix where pushing changes back to PR failed since branch wasn't…
amruthvvkp Sep 8, 2023
7cb7d00
Fixed a bug in config.py that caused pytest failures
amruthvvkp Sep 10, 2023
931aad5
Fixed a bug in config.py that caused pytest failures
amruthvvkp Sep 10, 2023
b3d445b
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 10, 2023
7843506
Fixed broken merge on pr-checks
amruthvvkp Sep 10, 2023
412dadb
Another fix to get PR checks running
amruthvvkp Sep 10, 2023
4e4a6dc
Merge 412dadb44794349c1a96942397b4d5eccf3032e9 into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
5171639
Bump version to 0.0.8a3
actions-user Sep 10, 2023
607ac3d
Minor fixes to pr-checks to allow commenting on PR after publish and …
amruthvvkp Sep 10, 2023
d067e07
Merged check artifacts and build artifacts
amruthvvkp Sep 10, 2023
e4801de
Fixed linting error on pr-checks
amruthvvkp Sep 10, 2023
454a11c
Merge e4801de0dfd29639b756a214465e8243dd070c31 into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
815c04c
Bump version to 0.0.8a4
actions-user Sep 10, 2023
2fc7a8e
Minor fix for pr-checks
amruthvvkp Sep 10, 2023
d64eba9
Merge 2fc7a8e980a521936222cf74769653ee7f82f402 into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
bd65a7a
Bump version to 0.0.8a5
actions-user Sep 10, 2023
715db93
Minor fix to handle unexpected token error
amruthvvkp Sep 10, 2023
876543a
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 10, 2023
3259b75
Another fix, hopefully should sort pr-checks
amruthvvkp Sep 10, 2023
9379d33
Merge 3259b7591170456bfa9cccf867f06618cde178d4 into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
77a056e
Bump version to 0.0.8a6
actions-user Sep 10, 2023
9621d8a
Minor fix to syntax errors
amruthvvkp Sep 10, 2023
d733dde
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 10, 2023
f406d7f
Merge d733dde0895c2e70fa3a2e4146df991fec27fe50 into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
7dc6b26
Bump version to 0.0.8a7
actions-user Sep 10, 2023
0ecf410
Minor update to check existing artifact
amruthvvkp Sep 10, 2023
83ba368
Merge 0ecf4106a39aed71184b81e893ab31533c7741ea into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
6e2c826
Bump version to 0.0.8a8
actions-user Sep 10, 2023
3c0d52f
Modified check artifacts step into PS command
amruthvvkp Sep 10, 2023
b5f573f
Merge 3c0d52f73999a473811117f5a5a5abf52dee315b into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
ca4c65e
Bump version to 0.0.8a9
actions-user Sep 10, 2023
bbc10e8
Minor fox with Pytest execution on pr-checks
amruthvvkp Sep 10, 2023
18dd6fa
Merge bbc10e8bae6a563be721acc53c614f7394519d58 into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
6967221
Bump version to 0.0.8a10
actions-user Sep 10, 2023
042a1da
Updated pr-checks to allow linting checks to run without depending Py…
amruthvvkp Sep 10, 2023
41ed74b
Fixed broken Pytest command
amruthvvkp Sep 10, 2023
50a73f5
Create interrogate badge
amruthvvkp Sep 10, 2023
e208468
Merge 50a73f5c1c915d2f2beb3f39e868943fd67944f4 into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
7408b8f
Minor updates
amruthvvkp Sep 10, 2023
50aa683
Merge 7408b8fcf21c837ea65c0ecf241d85158c206349 into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
6f9323b
Another fix for pr-checks
amruthvvkp Sep 10, 2023
57e7f2e
Merge 6f9323b3e30a61f3a97248654fc5959a4e1a1e80 into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
e214603
Minor update to pr-checks
amruthvvkp Sep 10, 2023
50517c5
Minor fix to curl command
amruthvvkp Sep 10, 2023
2769e3b
Merge 50517c5f7f209d9eba5535be133405db62b3619f into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
7ad13db
Minor update to fetch all artifacts
amruthvvkp Sep 10, 2023
5bd0c2c
Fixed infinite loop to check for Python package
amruthvvkp Sep 10, 2023
702ff3b
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 10, 2023
ea708a2
Merge 702ff3bea6ede6d53e2a3b2e273bf7aaf6dc0561 into c8c7ffcb816aacdef…
amruthvvkp Sep 10, 2023
53a777c
Bump version to 0.0.8a11
actions-user Sep 10, 2023
232e015
Fixed a bug that caused repeated comments to PR
amruthvvkp Sep 11, 2023
a65a938
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 11, 2023
8b8a42d
Merge a65a9383eb20d6050f04074dd2309bdf28896be2 into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
755a39c
Bump version to 0.0.8a12
actions-user Sep 11, 2023
7db06cc
Updated Download Artifact step
amruthvvkp Sep 11, 2023
e868e5b
Merge 7db06cc178920b722c1cc542b4e92b30f8f18d8a into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
dc6cd6c
Bump version to 0.0.8a13
actions-user Sep 11, 2023
33b2c89
Updated path to PyTests where escaped charecter is not available
amruthvvkp Sep 11, 2023
315a06b
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 11, 2023
f7b1138
Merge 315a06bf35a599b35982994af6f8fe88b96c824a into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
9f5a97d
Fix for PyTest
amruthvvkp Sep 11, 2023
6ebc79b
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 11, 2023
d92afbf
Merge 6ebc79bf67857c79712398fe051149f63f6d793b into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
568e827
Bump version to 0.0.8a14
actions-user Sep 11, 2023
f2d6196
Bare minimum to allow Pytest to run
amruthvvkp Sep 11, 2023
dfaa8ef
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 11, 2023
b43d36f
Merge dfaa8ef1039d7531879a6c0fc19b8d8390895e46 into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
c0311ea
Adding --verbose to pyTest to allow more meaningful logging
amruthvvkp Sep 11, 2023
a1c002d
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 11, 2023
2478981
Merge a1c002d46df5f35a2199d7607d24eb84fe6d3457 into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
257a2ff
Bump version to 0.0.8a15
actions-user Sep 11, 2023
b9a20f7
Another attempt to fix pytest
amruthvvkp Sep 11, 2023
62d3872
Merge b9a20f713c528c4e4b62b512c11d111c207dcbb5 into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
ab9f046
Bump version to 0.0.8a16
actions-user Sep 11, 2023
a47ea19
Another fix for PyTest
amruthvvkp Sep 11, 2023
b3dbda2
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 11, 2023
ab035ef
Merge b3dbda27c48687606fb504a5f139013d6d638ede into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
068cbb4
Bump version to 0.0.8a17
actions-user Sep 11, 2023
6f287d1
Added pytest-md pytest-emoji to test dependencies
amruthvvkp Sep 11, 2023
242f2e4
Merge 6f287d14c6dc5d13b7e833f31c0622d268f856c6 into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
ab10a72
Bump version to 0.0.8a18
actions-user Sep 11, 2023
db91a07
Added env:DISPLAY: ':99.0' to resolve PyTest aborted with 134 error
amruthvvkp Sep 11, 2023
3c11b74
Merge db91a07789d3e46a02f17be8a289213a51bff007 into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
5e148eb
Bump version to 0.0.8a19
actions-user Sep 11, 2023
b6f10c2
Added max memory usage option to Pytest for fixing 134 error
amruthvvkp Sep 11, 2023
50e1f14
Merge b6f10c2f53f0360ea4da063af72c31502dea7127 into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
f996648
Bump version to 0.0.8a20
actions-user Sep 11, 2023
8c5924f
Added pyqt to alow UI testing
amruthvvkp Sep 11, 2023
669e4ca
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 11, 2023
a8e6274
Merge 669e4ca06d06366dd5d9fe00a4b3df7857d8d00c into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
4a28be5
Bump version to 0.0.8a21
actions-user Sep 11, 2023
dcc4264
Updated environment variables for pytest-qt
amruthvvkp Sep 11, 2023
052da7a
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 11, 2023
a7eaf13
Merge 052da7a572b5c6f297dd6869b2f95f1a30426b93 into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
9077d1d
Bump version to 0.0.8a22
actions-user Sep 11, 2023
42bcb03
Added PyQt5 to test dependencies
amruthvvkp Sep 11, 2023
54bd347
Merge branch 'amruthvvkp/issue53' of https://github.com/amruthvvkp/fl…
amruthvvkp Sep 11, 2023
ec324ca
Merge 54bd3470f7f024aec8cccd8119d16660b3b657d1 into c8c7ffcb816aacdef…
amruthvvkp Sep 11, 2023
388523d
Pre-Commit now creates 3 different requirements files - one for core,…
amruthvvkp Sep 11, 2023
68dfbd5
Updated appveyor image to VS 2022 for .Net 6.0
amruthvvkp Sep 11, 2023
45fb663
Removed appveyor build phase
amruthvvkp Sep 11, 2023
f21abda
Minor change to appveyor configuration to properly run build script
amruthvvkp Sep 11, 2023
1791178
Reverted before_build, turned off build for appveyor
amruthvvkp Sep 11, 2023
552380c
Added branch validation rules
amruthvvkp Sep 11, 2023
af9d098
Updated branch to run CI everywhere except master branch
amruthvvkp Sep 11, 2023
426be65
Minor update to fix build script location
amruthvvkp Sep 11, 2023
a016ce2
Minor bug fix to allow build to happen on appveyor
amruthvvkp Sep 11, 2023
bd71a03
Minor update to build phase of appveyor
amruthvvkp Sep 11, 2023
f7581fb
Bug fix on invalid yaml
amruthvvkp Sep 11, 2023
e5c16f6
Added missing folder fix to move built artifacts
amruthvvkp Sep 11, 2023
3744161
Added change directory before running Pytest
amruthvvkp Sep 11, 2023
e5e0988
Fixed typo error on requirements-unit-test.txt
amruthvvkp Sep 11, 2023
e3ca850
minor update to fix relative path of artifacts after test
amruthvvkp Sep 11, 2023
6f51001
Fixed old version of Ruff deleting Python file content on save
amruthvvkp Sep 12, 2023
611eff9
Fixed GitHub actions on a small typo error
amruthvvkp Sep 21, 2023
8468333
Merge branch 'master' into amruthvvkp/issue53
varshithvvs Sep 24, 2023
13dfb77
Merge branch 'master' into amruthvvkp/issue53
varshithvvs Sep 24, 2023
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
115 changes: 115 additions & 0 deletions .appveyor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
version: 1.0.{build}
branches:
except:
- master
image: Visual Studio 2022
environment:
matrix:
- job_name: Python 3.7 x86
PYTHON: "C:\\Python37"
PYTHON_VERSION: 3.7
PYTHON_ARCH: 32

- job_name: Python 3.8 x86
PYTHON: "C:\\Python38"
PYTHON_VERSION: 3.8
PYTHON_ARCH: 32

- job_name: Python 3.9 x86
PYTHON: "C:\\Python39"
PYTHON_VERSION: 3.9
PYTHON_ARCH: 32

- job_name: Python 3.10 x86
PYTHON: "C:\\Python310"
PYTHON_VERSION: 3.10
PYTHON_ARCH: 32

- job_name: Python 3.11 x86
PYTHON: "C:\\Python311"
PYTHON_VERSION: 3.11
PYTHON_ARCH: 32

- job_name: Python 3.7 x64
PYTHON: "C:\\Python37-x64"
PYTHON_VERSION: 3.7
PYTHON_ARCH: 64

- job_name: Python 3.8 x64
PYTHON: "C:\\Python38-x64"
PYTHON_VERSION: 3.8
PYTHON_ARCH: 64

- job_name: Python 3.9 x64
PYTHON: "C:\\Python39-x64"
PYTHON_VERSION: 3.9
PYTHON_ARCH: 64

- job_name: Python 3.10 x64
PYTHON: "C:\\Python310-x64"
PYTHON_VERSION: 3.10
PYTHON_ARCH: 64

- job_name: Python 3.11 x64
PYTHON: "C:\\Python311"
PYTHON_VERSION: 3.11
PYTHON_ARCH: 64

init:
- ECHO %PYTHON% %PYTHON_VERSION% %PYTHON_ARCH%
install:
- cmd: >-
set PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%

python --version

before_build:
- cmd: git clone https://github.com/FlaUI/FlaUI.git C:\projects\FlaUI

build_script:
- ps: |
# Run PowerShell script
& "C:\\projects\\FlaUI\\build.ps1"

after_build:
- ps: |
New-Item -ItemType Directory -Path "C:\projects\flaui-uiautomation-wrapper\test_applications\WPFApplication" -Force | Out-Null
Copy-Item -Path "C:\projects\FlaUI\src\TestApplications\WpfApplication\bin\*" -Destination "C:\projects\flaui-uiautomation-wrapper\test_applications\WPFApplication" -Recurse -Force
New-Item -ItemType Directory -Path "C:\projects\flaui-uiautomation-wrapper\test_applications\WinFormsApplication" -Force | Out-Null
Copy-Item -Path "C:\projects\FlaUI\src\TestApplications\WinFormsApplication\bin\*" -Destination "C:\projects\flaui-uiautomation-wrapper\test_applications\WinFormsApplication" -Recurse -Force

before_test:
- cmd: cd "C:\projects\flaui-uiautomation-wrapper" && python -m pip install --upgrade pip && python -m pip install -r requirements.txt && python -m pip install -r requirements-unit-test.txt

test_script:
- cmd: >-
cd "C:\projects\flaui-uiautomation-wrapper" && python -m pytest --cov=flaui --cov-report=xml --cov-report=html --cov-report=term-missing --junitxml=test-results.xml

artifacts:
- path: test-results.xml
name: test-results

- path: coverage.xml
name: coverage

- path: htmlcov
name: coverage-html

- path: test_applications
name: test-applications

on_finish:
- ps: >-
$wc = New-Object 'System.Net.WebClient'

if (Test-Path .test-results.xml) {
$wc.UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path .test-results.xml))
}

if (Test-Path .coverage.xml) {
$wc.UploadFile("https://ci.appveyor.com/api/testresults/coverage/$($env:APPVEYOR_JOB_ID)", (Resolve-Path .coverage.xml))
}

if (Test-Path "C:/projects/FlaUI/artifacts/UnitTestResult.xml") {
$wc.UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", "C:/projects/FlaUI/artifacts/UnitTestResult.xml")
}
163 changes: 163 additions & 0 deletions .github/workflows/pr-checks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,163 @@
name: PR Checks

on:
pull_request:
branches: [master]
types: [opened]

permissions:
contents: write
pull-requests: write
id-token: write

jobs:
linting_checks:
name: Validations with Ruff, Interrogate
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
persist-credentials: false

- name: Run Ruff checks
uses: chartboost/ruff-action@v1
with:
src: "."
args: --format=github --target-version=py311

- name: Python Interrogate Check
uses: JackMcKew/python-interrogate-check@main
with:
path: flaui
badge-location: "badges/interrogate_badge.svg"

- name: Commit files
run: |
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add badges/interrogate_badge.svg
git diff --exit-code || git commit -m "Update interrogate_badge.svg" -a

- name: Push changes
if: success()
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.head_ref }}

publish:
name: Publish to Test PyPI
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
persist-credentials: false

- name: Set up Python 3.x
uses: actions/setup-python@v4
with:
python-version: "3.x"

- name: Setup Poetry
run: |
curl -sSL https://install.python-poetry.org | python3 -
echo "$HOME/.local/bin" >> $GITHUB_PATH
poetry config virtualenvs.in-project true

- name: Get latest version from Test PyPI
id: get_latest_version
run: |
current_version=$(curl -s https://test.pypi.org/pypi/flaui-uiautomation-wrapper/json | jq -r '.releases | to_entries | sort_by(.value[0].upload_time) | .[-1].key')
echo "current_version=$current_version" >> "$GITHUB_OUTPUT"

- name: Update package version
id: update_version
run: |
poetry version "${{ steps.get_latest_version.outputs.current_version }}"
while true; do
poetry version prerelease
updated_version=$(poetry version | cut -d' ' -f2)
url="https://test.pypi.org/simple/flaui-uiautomation-wrapper/flaui_uiautomation_wrapper-$updated_version-py3-none-any.whl"
status=$(curl -s -o /dev/null -w "%{http_code}" $url)
if [ $status -eq 200 ]; then
echo "Package found on Test PyPI for version $updated_version"
elif [ $status -eq 404 ]; then
echo "Package not found on Test PyPI for version $updated_version"
echo "updated_version=$updated_version" >> $GITHUB_OUTPUT
break
else
echo "Error checking Test PyPI status: $status"
exit 1
fi
done

- name: Build and publish distribution 📦 to Test PyPI
uses: JRubics/poetry-publish@v1.17
with:
pypi_token: ${{ secrets.TEST_PYPI_API_TOKEN }}
allow_poetry_pre_release: "yes"
ignore_dev_requirements: "yes"
repository_url: https://test.pypi.org/legacy/
repository_name: flaui-uiautomation-wrapper

- name: Commit files
run: |
git config user.email "actions@github.com"
git config user.name "GitHub Actions"
git add pyproject.toml
git commit -m "Bump version to $(poetry version | cut -d' ' -f2)"

- name: Push changes
if: success()
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.head_ref }}

- name: Comment on pull request
uses: actions/github-script@v6
env:
UPGRADED_POETRY_VERSION: ${{ steps.update_version.outputs.updated_version }}
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
// 1. Retrieve existing bot comments for the PR
const { data: comments } = await github.rest.issues.listComments({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
})
const botComment = comments.find(comment => {
return comment.user.type === 'Bot' && comment.body.includes('Deployed to Test PyPI')
})

// 2. Prepare format of the comment
const output = `#### Deployed to Test PyPI 🚀

<details>
The package version \`${process.env.UPGRADED_POETRY_VERSION}\` has been published to Test PyPI. Please test and verify the package before publishing to PyPI - https://test.pypi.org/project/flaui-uiautomation-wrapper/${process.env.UPGRADED_POETRY_VERSION}/
</details>

*Pusher: @${{ github.actor }}, Action: \`${{ github.event_name }}\`, Workflow: \`${{ github.workflow }}\`*`;

// 3. If we have a comment, update it, otherwise create a new one
if (botComment) {
github.rest.issues.updateComment({
owner: context.repo.owner,
repo: context.repo.repo,
comment_id: botComment.id,
body: output
})
} else {
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: output
})
}
42 changes: 0 additions & 42 deletions .github/workflows/python-package.yml

This file was deleted.

49 changes: 35 additions & 14 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,29 +13,50 @@ on:
types: [published]

permissions:
contents: read
contents: write
pull-requests: write
id-token: write

jobs:
deploy:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Get release tag
id: get_tag
run: echo ::set-output name=tag::${GITHUB_REF#refs/tags/}

- uses: actions/checkout@v4
with:
ref: ${{ steps.get_tag.outputs.tag }}

- name: Set up Python
uses: actions/setup-python@v3
uses: actions/setup-python@v4
with:
python-version: "3.x"
- name: Build package
run: poetry build
- name: Publish distribution 📦 to Test PyPI
uses: JRubics/poetry-publish@v1.13

- name: Setup Poetry
run: |
curl -sSL https://install.python-poetry.org | python3 -
echo "$HOME/.local/bin" >> $GITHUB_PATH
poetry config virtualenvs.in-project true

- name: Update version
run: poetry version $(echo ${{ steps.get_tag.outputs.tag }} | cut -d "v" -f 2)

- name: Build and Publish distribution 📦 to PyPI
if: startsWith(github.ref, 'refs/tags')
uses: JRubics/poetry-publish@v1.17
with:
pypi_token: ${{ secrets.TEST_PYPI_API_TOKEN }}
repository_url: https://test.pypi.org/legacy/
repository_name: flaui-uiautomation-wrapper
pypi_token: ${{ secrets.PYPI_API_TOKEN }}
allow_poetry_pre_release: "yes"
- name: Publish distribution 📦 to PyPI
if: startsWith(github.ref, 'refs/tags')
uses: JRubics/poetry-publish@v1.13
ignore_dev_requirements: "yes"
repository_name: flaui-uiautomation-wrapper

- name: Commit changes
if: success()
uses: stefanzweifel/git-auto-commit-action@v4
with:
pypi_token: ${{ secrets.PYPI_API_TOKEN }}
commit_message: "Update Poetry version to ${{ github.ref }}"
commit_options: "--no-verify"
branch: "master"
Loading