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
23 changes: 19 additions & 4 deletions .github/workflows/publish-tag.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,17 @@ jobs:
runs-on: ubuntu-latest

permissions:
contents: 'read'
contents: 'write'
id-token: 'write'

steps:
- id: checkout
name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6

- id: auth
name: Authenticate with Google Cloud
uses: google-github-actions/auth@v2
uses: google-github-actions/auth@v3
with:
token_format: access_token
workload_identity_provider: projects/51853309262/locations/global/workloadIdentityPools/my-pool/providers/my-provider
Expand All @@ -34,7 +34,7 @@ jobs:
cat app/pyproject.toml

- name: Setup Python
uses: actions/setup-python@v3
uses: actions/setup-python@v6

- name: Install Dependencies
run: |
Expand All @@ -60,3 +60,18 @@ jobs:
gcloud config set artifacts/location europe-west1
gcloud artifacts print-settings python > ~/.pypirc
python -m twine upload --repository python dist/*

- name: Check if pre-release
id: check_prerelease
run: |
if [[ "${{ github.ref_name }}" =~ ^[0-9]+\.[0-9]+\.[0-9]+-[0-9]+$ ]]; then
echo "prerelease=false" >> $GITHUB_OUTPUT
else
echo "prerelease=true" >> $GITHUB_OUTPUT
fi

- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
generate_release_notes: true
prerelease: ${{ steps.check_prerelease.outputs.prerelease }}
5 changes: 3 additions & 2 deletions app/src/zcs/core/logger/logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,9 @@ def record_factory(*args, **kwargs):

# Set original exception value if needed
record.original_exception = None
if args[6] is not None:
for arg in args[6]:
value = args[6] if len(args) > 6 else None
if isinstance(value, (list, tuple, set)):
for arg in value:
if isinstance(arg, Exception):
record.original_exception = arg
if isinstance(arg, ZcsException):
Expand Down
Loading