Skip to content

Commit

Permalink
Merge branch 'tektronix:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelwagoner authored Feb 7, 2024
2 parents ae943d0 + 0dabe4b commit bfa0cd0
Show file tree
Hide file tree
Showing 515 changed files with 101,231 additions and 12,438 deletions.
5 changes: 5 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,10 @@
# will be requested for review when someone opens a pull request.
* @tektronix/tm-devices-admin

/docs/ @tektronix/tm-devices-maintainers
/examples/ @tektronix/tm-devices-maintainers
/src/ @tektronix/tm-devices-maintainers
/tests/ @tektronix/tm-devices-maintainers

# Protect the configuration files
.github/ @tektronix/tm-devices-admin
2 changes: 0 additions & 2 deletions .github/auto_assign.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
---
addReviewers: true
addAssignees: author
reviewers: [tektronix/tm-devices-maintainers]
10 changes: 8 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,21 @@ updates:
- package-ecosystem: github-actions
directory: /
schedule:
interval: monthly
interval: weekly
groups:
gh-actions-dependencies:
patterns: ['*']
labels: [gh-actions, dependencies]
commit-message:
prefix: gh-actions
include: scope
- package-ecosystem: pip
directory: /
schedule:
interval: monthly
interval: weekly
groups:
python-dependencies:
patterns: ['*']
labels: [python, dependencies]
commit-message:
prefix: python-deps
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/assign-reviewers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ jobs:
# public_repo and read:org permissions. It also needs to be from an account that is
# part of the tektronix GitHub organization.
repo-token: ${{ secrets.ASSIGN_REVIEWERS_TOKEN }}
teams: tm-devices-maintainers
teams: tm-devices-maintainers,tm-devices-admin
6 changes: 3 additions & 3 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@ jobs:
language: [python]
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
queries: security-extended,security-and-quality
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
uses: github/codeql-action/analyze@v3
with:
category: /language:${{matrix.language}}
17 changes: 17 additions & 0 deletions .github/workflows/dependency-review.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
name: Pull Request Dependency Review
on:
pull_request:
branches: [main]
permissions:
contents: read
pull-requests: write
jobs:
dependency-review:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/dependency-review-action@v4
with:
fail-on-severity: low
comment-summary-in-pr: on-failure
39 changes: 39 additions & 0 deletions .github/workflows/deploy-documentation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
---
name: Deploy Docs to Github Pages
on:
workflow_run:
branches: [main]
workflows: [Test docs]
types: [completed]
concurrency:
group: publish-docs
jobs:
publish-docs:
runs-on: ubuntu-latest
if: github.repository == 'tektronix/tm_devices' && github.event.workflow_run.conclusion
== 'success' && github.ref == 'refs/heads/main'
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Download Artifact
uses: dawidd6/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
run_id: ${{ github.event.workflow_run.id }}
workflow_conclusion: success
name: artifact_docs
- name: Unzip Documentation Results
run: |
unzip docs_results.zip
rm -r .results_docs/html/.doctrees
- name: Upload To Pages
uses: actions/upload-pages-artifact@v3
with:
path: .results_docs/html
- name: Deploy To Pages
uses: actions/deploy-pages@v4
id: deployment
6 changes: 3 additions & 3 deletions .github/workflows/package-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ jobs:
runs-on: ubuntu-latest
environment: package-build
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: hynek/build-and-inspect-python-package@v1.5
- uses: hynek/build-and-inspect-python-package@v2.0.1
id: build-pkg
- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: x # any version
check-latest: true
Expand Down
38 changes: 23 additions & 15 deletions .github/workflows/package-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,34 +15,42 @@ on:
concurrency:
group: pypi
jobs:
print-inputs:
runs-on: ubuntu-latest
steps:
- name: Create summary of workflow inputs
run: |
echo "### inputs" >> $GITHUB_STEP_SUMMARY
echo "- release_level: ${{ inputs.release_level }}" >> $GITHUB_STEP_SUMMARY
# This job requires a Personal Access Token (Classic) with
# the public_repo permission. It also needs a private/public
# ssh key pair that can be used for signing. The public key must
# be attached to the account as an SSH signing key.
pypi-version:
name: Update package version
needs: [print-inputs]
if: github.repository == 'tektronix/tm_devices' && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
environment: package-release-gate
permissions:
id-token: write
contents: write
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.TEK_OPENSOURCE_TOKEN }}
- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: x
check-latest: true
- name: Check for unreleased entries in the Changelog and copy files to templates
run: |
python scripts/check_unreleased_changelog_items.py
git add python_semantic_release_templates
git config --global tag.gpgSign true
- name: Python Semantic Release
uses: python-semantic-release/python-semantic-release@v8.2.0 # 8.3.0 has a bug in the version output variable
uses: python-semantic-release/python-semantic-release@v8.7.2
id: release
with:
force: ${{ inputs.release_level }}
Expand All @@ -60,12 +68,12 @@ jobs:
if: github.repository == 'tektronix/tm_devices' && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
ref: main # Make sure to check out the latest commit on main, not the original commit that triggered the workflow
fetch-depth: 0
- name: Build package
uses: hynek/build-and-inspect-python-package@v1.5
uses: hynek/build-and-inspect-python-package@v2.0.1
upload-testpypi:
name: Upload package to TestPyPI
needs: [pypi-build]
Expand All @@ -76,12 +84,12 @@ jobs:
id-token: write
steps:
- name: Download built packages
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: Packages
path: dist
- name: Upload package to Test PyPI
uses: pypa/[email protected].8
uses: pypa/[email protected].11
with:
repository-url: https://test.pypi.org/legacy/
upload-pypi:
Expand All @@ -94,12 +102,12 @@ jobs:
id-token: write
steps:
- name: Download built packages
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: Packages
path: dist
- name: Upload package to PyPI
uses: pypa/[email protected].8
uses: pypa/[email protected].11
upload-github:
name: Upload package to GitHub Release
needs: [upload-pypi]
Expand All @@ -109,12 +117,12 @@ jobs:
id-token: write
contents: write
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
ref: main # Make sure to check out the latest commit on main, not the original commit that triggered the workflow
fetch-depth: 0
- name: Download built packages
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: Packages
path: dist
Expand All @@ -141,15 +149,15 @@ jobs:
- ' --index-url=https://test.pypi.org/simple/ --extra-index-url=https://pypi.org/simple'
steps:
- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: x
check-latest: true
- name: Test installing package
# A retry is used to allow for some downtime before the package is installable
uses: nick-fields/retry@v2
uses: nick-fields/retry@v3
with:
timeout_minutes: 2
timeout_minutes: 10
max_attempts: 5
retry_wait_seconds: 30
warning_on_retry: false
Expand Down
19 changes: 9 additions & 10 deletions .github/workflows/package-testpypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,13 @@ jobs:
if: github.repository == 'tektronix/tm_devices'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
# TODO: update to just "x", currently there appears to be a bug in hynek/build-and-inspect-python-package, where it uses an outdated version of typing_extensions.
python-version: 3.11
python-version: x
check-latest: true
- name: Install workflow dependencies
run: pip install poetry-core tomli tomli_w requests
Expand All @@ -33,7 +32,7 @@ jobs:
python scripts/project_version.py --set-version=$NEW_VERSION
echo "NEW_VERSION=$NEW_VERSION" >> $GITHUB_OUTPUT
- name: Build package
uses: hynek/build-and-inspect-python-package@v1.5
uses: hynek/build-and-inspect-python-package@v2.0.1
outputs:
built-version: ${{ steps.create-version.outputs.NEW_VERSION }}
test-pypi-upload:
Expand All @@ -46,12 +45,12 @@ jobs:
id-token: write
steps:
- name: Download built packages
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: Packages
path: dist
- name: Upload package to Test PyPI
uses: pypa/[email protected].8
uses: pypa/[email protected].11
with:
repository-url: https://test.pypi.org/legacy/
test-pypi-install:
Expand All @@ -61,15 +60,15 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: x
check-latest: true
- name: Test installing from test.pypi.org
# A retry is used to allow for some downtime before the package is installable
uses: nick-fields/retry@v2
uses: nick-fields/retry@v3
with:
timeout_minutes: 2
timeout_minutes: 10
max_attempts: 5
retry_wait_seconds: 30
warning_on_retry: false
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/tek-repo-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Check for CODEOWNERS
id: codeowners_file
uses: initialstate/file-check-action@v1
Expand All @@ -30,7 +30,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Check for README
id: readme_file
uses: initialstate/file-check-action@v1
Expand All @@ -48,7 +48,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Check for LICENSE
id: license_file
uses: initialstate/file-check-action@v1
Expand All @@ -66,7 +66,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Check for dependabot.yml
id: dependabot_file
uses: initialstate/file-check-action@v1
Expand All @@ -84,7 +84,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Check for codeql-analysis.yml
id: codeql-analysis_file
uses: initialstate/file-check-action@v1
Expand Down
Loading

0 comments on commit bfa0cd0

Please sign in to comment.