Skip to content

Commit

Permalink
Merge branch 'main' into christo/manifest-only-unit-test-fixturs
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristoGrab authored Dec 9, 2024
2 parents f0aef10 + a712441 commit dbbeeb2
Show file tree
Hide file tree
Showing 76 changed files with 1,340 additions and 2,637 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/autofix-command.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ jobs:
- name: Set up Poetry
uses: Gr1N/setup-poetry@v9
with:
poetry-version: "1.7.1"
poetry-version: "1.8.4"
- name: Set up Python
uses: actions/setup-python@v5
with:
Expand Down
24 changes: 17 additions & 7 deletions .github/workflows/connector-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,12 +88,14 @@ jobs:
# cdk_extra: n/a
# TODO: These are manifest connectors and won't work as expected until we
# add `--use-local-cdk` support for manifest connectors.
# - connector: source-the-guardian-api
# cdk_extra: n/a
# - connector: source-pokeapi
# cdk_extra: n/a
- connector: source-the-guardian-api
cdk_extra: n/a
- connector: source-pokeapi
cdk_extra: n/a

name: "Check: '${{matrix.connector}}' (skip=${{needs.cdk_changes.outputs['src'] == 'false' || needs.cdk_changes.outputs[matrix.cdk_extra] == 'false'}})"
permissions:
checks: write
steps:
- name: Abort if extra not changed (${{matrix.cdk_extra}})
id: no_changes
Expand Down Expand Up @@ -131,15 +133,18 @@ jobs:
run: |
cd airbyte
make tools.airbyte-ci-dev.install
airbyte-ci-dev connectors \
airbyte-ci-dev \
--ci-report-bucket-name=airbyte-ci-reports-multi \
connectors \
--name ${{matrix.connector}} \
--use-local-cdk \
test \
--fail-fast \
--skip-step qa_checks \
--skip-step connector_live_tests
- name: Evaluate Test Output
- name: Evaluate Test
id: evaluate_output
if: always() && steps.no_changes.outputs.status != 'cancelled'
run: |
# save job output json file as ci step output
Expand All @@ -148,17 +153,22 @@ jobs:
success=$(echo ${job_output} | jq -r '.success')
failed_step=$(echo ${job_output} | jq -r '.failed_steps | select(length > 0) | .[0] // "None"')
run_duration=$(echo ${job_output} | jq -r '.run_duration')
html_report_url=$(echo ${job_output} | jq -r '.html_report_url')
echo "## Job Output for ${{matrix.connector}}" >> $GITHUB_STEP_SUMMARY
echo "- [HTML Report](${html_report_url})" >> $GITHUB_STEP_SUMMARY
echo "- Success: ${success}" >> $GITHUB_STEP_SUMMARY
echo "- Test Duration: $(printf "%.0f" ${run_duration})s" >> $GITHUB_STEP_SUMMARY
if [ "${success}" != "true" ]; then
echo "- Failed Step: ${failed_step}" >> $GITHUB_STEP_SUMMARY
fi
echo -e "\n[Download Job Output](${{steps.upload_job_output.outputs.artifact-url}})" >> $GITHUB_STEP_SUMMARY
if [ "${success}" != "true" ]; then
echo "::error::Test failed for connector '${{ matrix.connector }}' on step '${failed_step}'. Check the logs for more details."
echo "::error::Test failed for connector '${{ matrix.connector }}' on step '${failed_step}'. "
exit 1
fi
echo "See the execution report for details: ${html_report_url}"
echo "success=${success}" >> $GITHUB_OUTPUT
echo "html_report_url=${html_report_url}" >> $GITHUB_OUTPUT
# Upload the job output to the artifacts
- name: Upload Job Output
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pdoc_preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Set up Poetry
uses: Gr1N/setup-poetry@v9
with:
poetry-version: "1.7.1"
poetry-version: "1.8.4"
- name: Set up Python
uses: actions/setup-python@v5
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pdoc_publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
- name: Set up Poetry
uses: Gr1N/setup-poetry@v9
with:
poetry-version: "1.7.1"
poetry-version: "1.8.4"
- name: Set up Python
uses: actions/setup-python@v5
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/poetry-lock-command.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ jobs:
- name: Set up Poetry
uses: Gr1N/setup-poetry@v9
with:
poetry-version: "1.7.1"
poetry-version: "1.8.4"
- name: Set up Python
uses: actions/setup-python@v5
with:
Expand Down
178 changes: 0 additions & 178 deletions .github/workflows/publish_sdm_connector.yml

This file was deleted.

13 changes: 6 additions & 7 deletions .github/workflows/pypi_publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ on:
workflow_dispatch:
inputs:
version:
description: "Version. The version to publish, ie 1.0.0 or 1.0.0-dev1. In most cases, you can leave this blank. If run from a release tag (recommended), the version number will be inferred from the git tag."
description: "Note that this workflow is intended for prereleases. For public-facing stable releases, please use the GitHub Releases workflow instead: https://github.com/airbytehq/airbyte-python-cdk/blob/main/docs/RELEASES.md. If running this workflow from main or from a dev branch, please enter the desired version number here, for instance 1.2.3dev0 or 1.2.3rc1."
required: false
publish_to_pypi:
description: "Publish to PyPI. If true, the workflow will publish to PyPI."
Expand All @@ -30,7 +30,7 @@ on:
description: "Update Connector Builder. If true, the workflow will create a PR to bump the CDK version used by Connector Builder."
type: boolean
required: true
default: true
default: false

jobs:
build:
Expand Down Expand Up @@ -150,11 +150,9 @@ jobs:

publish_sdm:
name: Publish SDM to DockerHub
# TODO: When we're ready to publish after each release, prefix the `if` below with:
# (github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')) ||
# Until then, this workflow needs to be kicked off manually.
# Last remaining blocker documented here: https://github.com/airbytehq/airbyte-python-cdk/issues/64
if: >
(github.event_name == 'push' &&
startsWith(github.ref, 'refs/tags/v')) ||
(github.event_name == 'workflow_dispatch' &&
github.event.inputs.publish_to_dockerhub == 'true'
)
Expand Down Expand Up @@ -249,6 +247,7 @@ jobs:
needs:
- build
- publish_cdk
- publish_sdm
if: >
(github.event_name == 'push' &&
needs.build.outputs.IS_PRERELEASE == 'false' &&
Expand Down Expand Up @@ -288,7 +287,7 @@ jobs:
pip-compile --upgrade
- name: Create Pull Request
id: create-pull-request
uses: peter-evans/create-pull-request@v6
uses: peter-evans/create-pull-request@v7
with:
token: ${{ secrets.GH_PAT_MAINTENANCE_OCTAVIA }}
commit-message: "chore: update CDK version following release"
Expand Down
10 changes: 9 additions & 1 deletion .github/workflows/pytest_fast.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,14 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Poetry
uses: Gr1N/setup-poetry@v9
with:
poetry-version: "1.8.4"

- name: Check Poetry lock file is current
run: poetry check

- uses: hynek/build-and-inspect-python-package@v2
env:
# Pass in dummy version '0.0.0dev0' version to appease dynamic versioning
Expand All @@ -36,7 +44,7 @@ jobs:
- name: Set up Poetry
uses: Gr1N/setup-poetry@v9
with:
poetry-version: "1.7.1"
poetry-version: "1.8.4"
- name: Set up Python
uses: actions/setup-python@v5
with:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/pytest_matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ jobs:
name: Pytest (All, Python ${{ matrix.python-version }}, ${{ matrix.os }})
# Don't run on forks. Run on pushes to main, and on PRs that are not from forks.
if: >
(github.event_name == 'push' && github.ref == 'refs/heads/main') ||
(github.event.pull_request.head.repo.fork == false)
github.event_name == 'pull_request' ||
(github.event_name == 'push' && github.ref == 'refs/heads/main')
strategy:
matrix:
python-version: [
Expand Down Expand Up @@ -61,7 +61,7 @@ jobs:
uses: Gr1N/setup-poetry@v9
if: steps.changes.outputs.src == 'true'
with:
poetry-version: "1.7.1"
poetry-version: "1.8.4"
- name: Set up Python
uses: actions/setup-python@v5
if: steps.changes.outputs.src == 'true'
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/python_lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- name: Set up Poetry
uses: Gr1N/setup-poetry@v9
with:
poetry-version: "1.7.1"
poetry-version: "1.8.4"
- name: Set up Python
uses: actions/setup-python@v5
with:
Expand All @@ -40,7 +40,7 @@ jobs:
- name: Set up Poetry
uses: Gr1N/setup-poetry@v9
with:
poetry-version: "1.7.1"
poetry-version: "1.8.4"
- name: Set up Python
uses: actions/setup-python@v5
with:
Expand All @@ -63,7 +63,7 @@ jobs:
- name: Set up Poetry
uses: Gr1N/setup-poetry@v9
with:
poetry-version: "1.7.1"
poetry-version: "1.8.4"
- name: Set up Python
uses: actions/setup-python@v5
with:
Expand Down
Loading

0 comments on commit dbbeeb2

Please sign in to comment.