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

Fix release action and overall CI jobs dependencies #261

Merged
merged 6 commits into from
Oct 17, 2024
Merged
Show file tree
Hide file tree
Changes from 5 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
30 changes: 29 additions & 1 deletion .github/workflows/test.yml → .github/workflows/cicd.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
name: test
name: Test and release related jobs

on:
push: # Run on pushes to the default branch
branches: [main]
pull_request_target: # Also run on pull requests originated from forks
branches: [main]
release:
types: ['published']
branches: [fix-release-action]

tatiana marked this conversation as resolved.
Show resolved Hide resolved
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
Expand All @@ -20,6 +23,8 @@ jobs:
- run: true

Static-Check:
needs:
- Authorize
runs-on: ubuntu-latest
tatiana marked this conversation as resolved.
Show resolved Hide resolved
steps:
- uses: actions/checkout@v4
Expand All @@ -35,6 +40,8 @@ jobs:
- run: CONFIG_ROOT_DIR=`pwd`"/dags" hatch run tests.py3.12-2.10:static-check

Run-Unit-Tests:
needs:
- Authorize
runs-on: ubuntu-latest
tatiana marked this conversation as resolved.
Show resolved Hide resolved
strategy:
fail-fast: false
Expand Down Expand Up @@ -140,3 +147,24 @@ jobs:
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}
files: coverage.xml

Publish-Package:
if: github.event_name == 'release'
name: Build and publish Python 🐍 distributions 📦 to PyPI
needs:
- Static-Check
- Run-Unit-Tests
- Code-Coverage
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
architecture: 'x64'
- run: pip3 install hatch
- run: hatch build
- run: hatch publish
env:
HATCH_INDEX_USER: __token__
HATCH_INDEX_AUTH: ${{ secrets.PYPI_TOKEN }}
20 changes: 0 additions & 20 deletions .github/workflows/release.yml

This file was deleted.

2 changes: 1 addition & 1 deletion dagfactory/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from .dagfactory import DagFactory, load_yaml_dags

__version__ = "0.20.0a1"
__version__ = "0.20.0a2"
__all__ = [
"DagFactory",
"load_yaml_dags",
Expand Down
Loading