Repository navigation
chore: prepare repo for multiple branches #54
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,17 +1,31 @@ | ||
| name: ci | ||
|
|
||
| on: | ||
| pull_request: | ||
| push: | ||
| branches: | ||
| - main | ||
| - '17' | ||
| pull_request: | ||
| branches: | ||
| - '17' | ||
|
|
||
| jobs: | ||
| pre-commit: | ||
| uses: coatl-dev/workflows/.github/workflows/pre-commit.yml@6803f1bf5290b457054db1b58d012c4887b6ada8 # v7.1.1 | ||
| with: | ||
| checkout-ref: ${{ github.ref }} | ||
| skip-hooks: 'pylint' | ||
| python-version: | | ||
| 3.12 | ||
| 3.15 | ||
|
|
||
| pylint: | ||
| uses: coatl-dev/workflows/.github/workflows/pylint.yml@d7cf5f9059f9a5fa365b8c9e06ff63f5d968ddb0 # v7.1.0 | ||
| uses: coatl-dev/workflows/.github/workflows/pylint.yml@6803f1bf5290b457054db1b58d012c4887b6ada8 # v7.1.1 | ||
| with: | ||
| path: src | ||
| checkout-ref: ${{ github.ref }} | ||
|
|
||
| tox: | ||
| if: ${{ github.event_name == 'pull_request' }} | ||
| uses: $/.github/workflows/tox.yml | ||
| with: | ||
| checkout-ref: ${{ github.ref }} | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2,19 +2,22 @@ name: publish | |
|
|
||
| on: | ||
| release: | ||
| types: | ||
| - published | ||
| types: [published] | ||
|
|
||
| jobs: | ||
| tox: | ||
| uses: $/.github/workflows/tox.yml | ||
| with: | ||
| checkout-ref: ${{ github.event.release.tag_name }} | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🟡 Medium · Untested code gets published When the release tag is moved after tox checks it out but before the upload job checks it out, the tox job resolves the release tag when it checks out the source, then the upload job resolves that tag again after tox finishes. If the tag is moved between those checkouts, PyPI receives code that tox did not test. Resolve the release tag to a commit SHA once and use that SHA for both testing and upload. Also at Prompt for AI agentsIn `.github/workflows/publish.yml` at line 11:
**Untested code gets published**
When the release tag is moved after tox checks it out but before the upload job checks it out, the tox job resolves the release tag when it checks out the source, then the upload job resolves that tag again after tox finishes. If the tag is moved between those checkouts, PyPI receives code that tox did not test.
Resolve the release tag to a commit SHA once and use that SHA for both testing and upload.
Also at `.github/workflows/publish.yml:20`. |
||
|
|
||
| pypi-upload: | ||
| needs: tox | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Checkout repo | ||
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | ||
| with: | ||
| ref: ${{ github.event.release.tag_name }} | ||
|
|
||
| - name: Upload package to PyPI | ||
| uses: coatl-dev/actions/pypi-upload@499c77f2bc6f909d372849058517ca2e39ce16d4 # v7.1.3 | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,17 +1,22 @@ | ||
| name: tox | ||
|
|
||
| on: | ||
| workflow_call: | ||
| inputs: | ||
| checkout-ref: | ||
| required: true | ||
| type: string | ||
|
|
||
| jobs: | ||
| tox-package: | ||
| uses: coatl-dev/workflows/.github/workflows/tox-docker.yml@d7cf5f9059f9a5fa365b8c9e06ff63f5d968ddb0 # v7.1.0 | ||
| uses: coatl-dev/workflows/.github/workflows/tox-docker.yml@6803f1bf5290b457054db1b58d012c4887b6ada8 # v7.1.1 | ||
| with: | ||
| checkout-ref: ${{ inputs.checkout-ref }} | ||
|
|
||
| tox-stubs: | ||
| uses: coatl-dev/workflows/.github/workflows/tox.yml@d7cf5f9059f9a5fa365b8c9e06ff63f5d968ddb0 # v7.1.0 | ||
| uses: coatl-dev/workflows/.github/workflows/tox.yml@6803f1bf5290b457054db1b58d012c4887b6ada8 # v7.1.1 | ||
| with: | ||
| python-versions: | | ||
| 3.10 | ||
| 3.11 | ||
| 3.12 | ||
| working-directory: stubs | ||
| checkout-ref: ${{ inputs.checkout-ref }} |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,9 +1,3 @@ | ||
| ci: | ||
| autoupdate_commit_msg: 'build(deps): pre-commit autoupdate' | ||
| autofix_commit_msg: 'style: apply auto fixes with pre-commit' | ||
| skip: | ||
| - pylint | ||
|
Comment on lines
-1
to
-5
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🟡 Medium · pre-commit.ci checks fail When pre-commit.ci runs the hooks without a Restore Prompt for AI agentsIn `.pre-commit-config.yaml` at lines 1-5:
**pre-commit.ci checks fail**
When pre-commit.ci runs the hooks without a `pylint` executable, the local `language: system` `pylint` hook is no longer skipped, so it invokes an executable the config does not install and the hosted check fails.
Restore `pylint` in the pre-commit.ci skip list or provision the executable for the hook. |
||
|
|
||
| repos: | ||
| - repo: https://github.com/aio-libs/sort-all | ||
| rev: v1.3.0 | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🟠 High · Branches receive no CI checks
When a push or pull request targets a branch other than
17,ci.ymlfilters both events to17, so pushes and pull requests targetingmainand other branches do not schedulepre-commit,pylint, ortox, leaving those branches without CI validation.Remove the branch filters from both triggers so the workflow runs for pushes and pull requests to all branches.
Also at
.github/workflows/ci.yml:6,.github/workflows/ci.yml:9.Prompt for AI agents