-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into dependabot/github_actions/styfle/cancel-work…
…flow-action-0.12.0
- Loading branch information
Showing
20 changed files
with
993 additions
and
85 deletions.
There are no files selected for viewing
This file contains 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,15 @@ | ||
* membrain-seg version: | ||
* Python version: | ||
* Operating System: | ||
|
||
### Description | ||
|
||
Describe what you were trying to get done. | ||
Tell us what happened, what went wrong, and what you expected to happen. | ||
|
||
### What I Did | ||
|
||
``` | ||
Paste the command(s) you ran and the output. | ||
If there was a crash, please include the traceback here. | ||
``` |
This file contains 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,12 @@ | ||
--- | ||
title: "{{ env.TITLE }}" | ||
labels: [bug] | ||
--- | ||
The {{ workflow }} workflow failed on {{ date | date("YYYY-MM-DD HH:mm") }} UTC | ||
|
||
The most recent failing test was on {{ env.PLATFORM }} py{{ env.PYTHON }} | ||
with commit: {{ sha }} | ||
|
||
Full run: https://github.com/{{ repo }}/actions/runs/{{ env.RUN_ID }} | ||
|
||
(This post will be updated if another test fails, as long as this issue remains open.) |
This file contains 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
This file contains 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 |
---|---|---|
|
@@ -9,13 +9,21 @@ on: | |
pull_request: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: "0 0 * * 0" # every week (for --pre release tests) | ||
# run every week (for --pre release tests) | ||
- cron: "0 0 * * 0" | ||
|
||
# cancel in-progress runs that use the same workflow and branch | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
check-manifest: | ||
# check-manifest is a tool that checks that all files in version control are | ||
# included in the sdist (unless explicitly excluded) | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
- run: pipx run check-manifest | ||
|
||
test: | ||
|
@@ -24,16 +32,16 @@ jobs: | |
strategy: | ||
fail-fast: false | ||
matrix: | ||
python-version: ['3.8', '3.9', '3.10'] | ||
platform: [ubuntu-latest, macos-latest, windows-latest] | ||
python-version: ["3.9", "3.10", "3.11"] | ||
platform: [ubuntu-latest] #, macos-latest, windows-latest] | ||
|
||
steps: | ||
- name: Cancel Previous Runs | ||
uses: styfle/[email protected] | ||
with: | ||
access_token: ${{ github.token }} | ||
|
||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v4 | ||
|
@@ -42,25 +50,25 @@ jobs: | |
cache-dependency-path: "pyproject.toml" | ||
cache: "pip" | ||
|
||
# if running a cron job, we add the --pre flag to test against pre-releases | ||
- name: Install dependencies | ||
- name: Install Dependencies | ||
run: | | ||
python -m pip install -U pip | ||
python -m pip install -e .[test] ${{ github.event_name == 'schedule' && '--pre' || '' }} | ||
# if running a cron job, we add the --pre flag to test against pre-releases | ||
python -m pip install .[test] ${{ github.event_name == 'schedule' && '--pre' || '' }} | ||
- name: Test | ||
- name: 🧪 Run Tests | ||
run: pytest --color=yes --cov --cov-report=xml --cov-report=term-missing | ||
|
||
# If something goes wrong, we can open an issue in the repo | ||
- name: Report --pre Failures | ||
# If something goes wrong with --pre tests, we can open an issue in the repo | ||
- name: 📝 Report --pre Failures | ||
if: failure() && github.event_name == 'schedule' | ||
uses: JasonEtco/create-an-issue@v2 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
PLATFORM: ${{ matrix.platform }} | ||
PYTHON: ${{ matrix.python-version }} | ||
RUN_ID: ${{ github.run_id }} | ||
TITLE: '[test-bot] pip install --pre is failing' | ||
TITLE: "[test-bot] pip install --pre is failing" | ||
with: | ||
filename: .github/TEST_FAIL_TEMPLATE.md | ||
update_existing: true | ||
|
@@ -74,28 +82,32 @@ jobs: | |
if: success() && startsWith(github.ref, 'refs/tags/') && github.event_name != 'schedule' | ||
runs-on: ubuntu-latest | ||
|
||
permissions: | ||
# IMPORTANT: this permission is mandatory for trusted publishing on PyPi | ||
# see https://docs.pypi.org/trusted-publishers/ | ||
id-token: write | ||
# This permission allows writing releases | ||
contents: write | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
- name: 🐍 Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.x" | ||
|
||
- name: install | ||
- name: 👷 Build | ||
run: | | ||
git tag | ||
pip install -U pip build twine | ||
python -m pip install build | ||
python -m build | ||
twine check dist/* | ||
ls -lh dist | ||
- name: Build and publish | ||
run: twine upload dist/* | ||
env: | ||
TWINE_USERNAME: __token__ | ||
TWINE_PASSWORD: ${{ secrets.TWINE_API_KEY }} | ||
- name: 🚢 Publish to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
password: ${{ secrets.TWINE_API_KEY }} | ||
|
||
- uses: softprops/action-gh-release@v1 | ||
with: | ||
generate_release_notes: true | ||
files: './dist/*' |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.