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
42 changes: 8 additions & 34 deletions .github/workflows/build_tests.yml
Original file line number Diff line number Diff line change
@@ -1,42 +1,16 @@
name: Run Build Tests
on:
push:
branches:
- master
branches: [master]
pull_request:
branches:
- dev
paths:
- 'requirements/**'
- 'setup.py'
branches: [dev]
workflow_dispatch:

jobs:
build_tests:
strategy:
max-parallel: 2
matrix:
python-version: ["3.10", "3.11"]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Build Tools
run: |
python -m pip install build wheel uv
- name: Install System Dependencies
run: |
sudo apt-get update
sudo apt install python3-dev swig libssl-dev libfann-dev portaudio19-dev libpulse-dev python3-fann2
- name: Build Source Packages
run: |
python setup.py sdist
- name: Build Distribution Packages
run: |
python setup.py bdist_wheel
- name: Install package
run: |
uv pip install --system .[mycroft,lgpl,plugins,skills-essential,skills-extra,skills-audio,skills-gui,skills-internet,skills-media,skills-desktop,skills-en,skills-ca,skills-pt]
uses: OpenVoiceOS/gh-automations/.github/workflows/build-tests.yml@dev
secrets: inherit
with:
system_deps: 'swig libssl-dev portaudio19-dev libpulse-dev libfann-dev'
install_extras: 'mycroft,plugins,skills-essential,lgpl,test'
test_path: 'test/unittests'
48 changes: 16 additions & 32 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -1,36 +1,20 @@
# .github/workflows/coverage.yml
name: Post coverage comment
name: Coverage Report

on:
workflow_run:
workflows: ["Run Tests"]
types:
- completed
push:
branches: [dev]
pull_request:
branches: [dev]
workflow_dispatch:

jobs:
test:
name: Run tests & display coverage
runs-on: ubuntu-latest
if: github.event.workflow_run.event == 'pull_request' && github.event.workflow_run.conclusion == 'success'
permissions:
# Gives the action the necessary permissions for publishing new
# comments in pull requests.
pull-requests: write
# Gives the action the necessary permissions for editing existing
# comments (to avoid publishing multiple comments in the same PR)
contents: write
# Gives the action the necessary permissions for looking up the
# workflow that launched this workflow, and download the related
# artifact that contains the comment to be published
actions: read
steps:
# DO NOT run actions/checkout here, for security reasons
# For details, refer to https://securitylab.github.com/research/github-actions-preventing-pwn-requests/
- name: Post comment
uses: py-cov-action/python-coverage-comment-action@v3
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_PR_RUN_ID: ${{ github.event.workflow_run.id }}
# Update those if you changed the default values:
# COMMENT_ARTIFACT_NAME: python-coverage-comment-action
# COMMENT_FILENAME: python-coverage-comment-action.txt
coverage:
uses: OpenVoiceOS/gh-automations/.github/workflows/coverage.yml@dev
secrets: inherit
with:
system_deps: 'python3-dev swig libssl-dev portaudio19-dev libpulse-dev libfann-dev'
install_extras: '.[mycroft,plugins,skills-essential,lgpl,test]'
test_path: 'test/'
coverage_source: 'ovos_core'
deploy_pages: true
gh_pages_branch: 'gh-pages'
46 changes: 0 additions & 46 deletions .github/workflows/gh_pages_coverage.yml

This file was deleted.

37 changes: 5 additions & 32 deletions .github/workflows/license_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,35 +10,8 @@ on:

jobs:
license_tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install Build Tools
run: |
python -m pip install build wheel uv
- name: Install System Dependencies
run: |
sudo apt-get update
sudo apt install python3-dev swig libssl-dev libfann-dev portaudio19-dev libpulse-dev
- name: Install core repo
run: |
uv pip install --system .[mycroft,lgpl,skills-essential]
- name: Get explicit and transitive dependencies
run: |
uv pip freeze > requirements-all.txt
- name: Check python
id: license_check_report
uses: pilosus/action-pip-license-checker@v0.5.0
with:
requirements: 'requirements-all.txt'
fail: 'Copyleft,Other,Error'
fails-only: true
exclude: '^(precise-runner|fann2|ovos-adapt-parser|ovos-padatious|tqdm|bs4|sonopy|caldav|recurring-ical-events|x-wr-timezone|zeroconf|mutagen|attrs).*'
exclude-license: '^(Mozilla).*$'
- name: Print report
if: ${{ always() }}
run: echo "${{ steps.license_check_report.outputs.report }}"
uses: OpenVoiceOS/gh-automations/.github/workflows/license-check.yml@dev
with:
install_extras: '[mycroft,lgpl,skills-essential]'
system_deps: 'swig libfann-dev portaudio19-dev libpulse-dev'
exclude_packages: '^(precise-runner|fann2|ovos-adapt-parser|ovos-padatious|tqdm|bs4|sonopy|caldav|recurring-ical-events|x-wr-timezone|zeroconf|mutagen|attrs).*'
42 changes: 13 additions & 29 deletions .github/workflows/pipaudit.yml
Original file line number Diff line number Diff line change
@@ -1,38 +1,22 @@
name: Run PipAudit

on:
push:
branches:
- master
- dev
pull_request:
branches:
- dev
workflow_dispatch:

jobs:
build_tests:
strategy:
max-parallel: 2
matrix:
python-version: ["3.10", "3.11"]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Build Tools
run: |
python -m pip install build wheel uv
- name: Install System Dependencies
run: |
sudo apt-get update
sudo apt install python3-dev swig libssl-dev
- name: Install package
run: |
uv pip install --system .[skills-essential]
- uses: pypa/gh-action-pip-audit@v1.0.0
with:
# Ignore setuptools vulnerability we can't do much about
# Ignore numpy vulnerability affecting latest version for Py3.7
ignore-vulns: |
GHSA-r9hx-vwmv-q579
GHSA-fpfv-jqm9-f5jm
pip_audit:
uses: OpenVoiceOS/gh-automations/.github/workflows/pip-audit.yml@dev
secrets: inherit
with:
system_deps: 'swig libssl-dev'
install_extras: '[skills-essential]'
ignore_vulns: |
GHSA-r9hx-vwmv-q579
GHSA-fpfv-jqm9-f5jm
49 changes: 4 additions & 45 deletions .github/workflows/publish_stable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,53 +6,12 @@ on:

jobs:
publish_stable:
uses: TigreGotico/gh-automations/.github/workflows/publish-stable.yml@master
if: github.actor != 'github-actions[bot]'
uses: OpenVoiceOS/gh-automations/.github/workflows/publish-stable.yml@dev
secrets: inherit
with:
branch: 'master'
version_file: 'ovos_core/version.py'
setup_py: 'setup.py'
publish_pypi: true
sync_dev: true
publish_release: true

publish_pypi:
needs: publish_stable
if: success() # Ensure this job only runs if the previous job succeeds
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: master
fetch-depth: 0 # otherwise, there would be errors pushing refs to the destination repository.
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install Build Tools
run: |
python -m pip install build wheel
- name: version
run: echo "::set-output name=version::$(python setup.py --version)"
id: version
- name: Build Distribution Packages
run: |
python setup.py sdist bdist_wheel
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@master
with:
password: ${{secrets.PYPI_TOKEN}}


sync_dev:
needs: publish_stable
if: success() # Ensure this job only runs if the previous job succeeds
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # otherwise, there would be errors pushing refs to the destination repository.
ref: master
- name: Push master -> dev
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: dev
Loading
Loading