Skip to content

Commit

Permalink
Merge branch 'master' into brian/sendgrid_upgrade_to_latest_for_async…
Browse files Browse the repository at this point in the history
…_retriever_refactor
  • Loading branch information
brianjlai committed Jan 8, 2025
2 parents d15f249 + ac054a6 commit 3f6ff97
Show file tree
Hide file tree
Showing 3,043 changed files with 52,703 additions and 43,242 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
2 changes: 1 addition & 1 deletion .github/actions/run-airbyte-ci/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ runs:
id: hash-subcommand
shell: bash
if: always()
run: echo "::set-output name=subcommand_hash::$(echo ${{ inputs.subcommand }} | sha256sum | cut -d ' ' -f 1)"
run: echo "subcommand_hash=$(echo ${{ inputs.subcommand }} | sha256sum | cut -d ' ' -f 1)" >> $GITHUB_OUTPUT

- name: Upload logs to GitHub
id: upload-dagger-engine-logs
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/airbyte-ci-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ jobs:
if: github.ref == 'refs/heads/master'
working-directory: airbyte-ci/connectors/pipelines/
run: |
echo "::set-output name=version::$(poetry version --short)"
echo "version=$(poetry version --short)" >> $GITHUB_OUTPUT
- name: Authenticate to Google Cloud Prod
id: auth_prod
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/airbyte-ci-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ on:
- synchronize
jobs:
changes:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
outputs:
internal_poetry_packages: ${{ steps.changes.outputs.internal_poetry_packages }}

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/approve-and-merge-dispatch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
types: [created]
jobs:
approveAndMergeDispatch:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Auto Approve Slash Command Dispatch
uses: peter-evans/slash-command-dispatch@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/approve-regression-tests-command.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ run-name: "Approve Regression Tests #${{ github.event.inputs.pr }}"
jobs:
approve-regression-tests:
name: "Approve Regression Tests"
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Get job variables
id: job-vars
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/assign-issue-to-project.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ env:

jobs:
assign_one_project:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
name: Assign to Airbyte Github Project
steps:
- name: Assign documentation issues to the Documentation Roadmap project
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/auto_merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
jobs:
run_auto_merge:
name: Run auto-merge
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/bump-version-command.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ concurrency:
jobs:
bump-version:
name: "Bump version of connectors in this PR"
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Get job variables
id: job-vars
Expand Down Expand Up @@ -100,7 +100,7 @@ jobs:
- name: Check for changes
id: git-diff
run: |
git diff --quiet && echo "No changes to commit" || echo "::set-output name=changes::true"
git diff --quiet && echo "No changes to commit" || echo "changes=true" >> $GITHUB_OUTPUT
shell: bash

# Commit changes (if any)
Expand Down
41 changes: 1 addition & 40 deletions .github/workflows/community_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
fail_on_protected_path_changes:
name: "Check fork do not change protected paths"
if: github.event.pull_request.head.repo.fork == true
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
permissions:
pull-requests: read
steps:
Expand All @@ -37,45 +37,6 @@ jobs:
echo "The fork has changes in protected paths. This is not allowed."
exit 1
format_check:
# IMPORTANT: This name must match the require check name on the branch protection settings
name: "Check for formatting errors"
if: github.event.pull_request.head.repo.fork == true
environment: community-ci-auto
runs-on: community-tooling-test-small
needs: fail_on_protected_path_changes
timeout-minutes: 30
env:
MAIN_BRANCH_NAME: "master"
steps:
# This checkouts a fork which can contain untrusted code
# It's deemed safe as the formatter are not executing any checked out code
- name: Checkout fork
uses: actions/checkout@v4
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 1

# This will sync the .github folder of the main repo with the fork
# This allows us to use up to date actions and CI logic from the main repo
- name: Pull .github folder and internal packages from main repository
id: pull_github_folder
run: |
git remote add main https://github.com/airbytehq/airbyte.git
git fetch main ${MAIN_BRANCH_NAME}
git checkout main/${MAIN_BRANCH_NAME} -- .github
git checkout main/${MAIN_BRANCH_NAME} -- airbyte-ci
- name: Run airbyte-ci format check all
# This path refers to the fork .github folder.
# We make sure its content is in sync with the main repo .github folder by pulling it in the previous step
uses: ./.github/actions/run-airbyte-ci
with:
context: "pull_request"
sentry_dsn: ${{ secrets.SENTRY_AIRBYTE_CI_DSN }}
subcommand: "format check all"
is_fork: "true"
connectors_early_ci:
name: Run connectors early CI on fork
if: github.event.pull_request.head.repo.fork == true
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/connector-performance-command.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,15 +92,15 @@ jobs:
uuid:
name: "Custom UUID of workflow run"
timeout-minutes: 10
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: UUID ${{ inputs.uuid }}
run: true
start-test-runner:
name: Start Build EC2 Runner
needs: uuid
timeout-minutes: 10
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
outputs:
label: ${{ steps.start-ec2-runner.outputs.label }}
ec2-instance-id: ${{ steps.start-ec2-runner.outputs.ec2-instance-id }}
Expand Down Expand Up @@ -262,7 +262,7 @@ jobs:
- start-test-runner # required to get output from the start-runner job
- performance-test # required to wait when the main job is done
- uuid
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
if: ${{ always() }} # required to stop the runner even if the error happened in the previous jobs
steps:
- name: Configure AWS credentials
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/connector_code_freeze.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ env:
CODE_FREEZE_END_DATE: "2024-01-02"
jobs:
code-freeze-check:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
name: Code freeze check
permissions:
# This is required to be able to comment on PRs and list changed files
Expand All @@ -35,10 +35,10 @@ jobs:
if [ "$current_date" -ge "$start_date" ] && [ "$current_date" -le "$end_date" ]; then
echo "Code freeze is in effect"
echo "::set-output name=is_in_code_freeze::true"
echo "is_in_code_freeze=true" >> $GITHUB_OUTPUT
else
echo "Code freeze is not in effect"
echo "::set-output name=is_in_code_freeze::false"
echo "is_in_code_freeze=false" >> $GITHUB_OUTPUT
fi
# Use GitHub PR Api to get the list of changed files
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/connector_teams_review_requirements.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ on:
jobs:
check-review-requirements:
name: "Check if a review is required from Connector teams"
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

if: ${{ github.event.pull_request.head.repo.fork == false && github.event.pull_request.draft == false }}
steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/connectors_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ on:
- synchronize
jobs:
changes:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
outputs:
connectors: ${{ steps.changes.outputs.connectors }}
permissions:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/connectors_up_to_date.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ on:
jobs:
generate_matrix:
name: Generate matrix
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
outputs:
generated_matrix: ${{ steps.generate_matrix.outputs.generated_matrix }}
steps:
Expand All @@ -41,7 +41,7 @@ jobs:
id: generate_matrix
run: |
matrix=$(jq -c -r '{include: [.[] | "--name=" + .] | to_entries | group_by(.key / 100 | floor) | map(map(.value) | {"connector_names": join(" ")})}' selected_connectors.json)
echo "::set-output name=generated_matrix::$matrix"
echo "generated_matrix=$matrix" >> $GITHUB_OUTPUT
run_connectors_up_to_date:
needs: generate_matrix
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/contractors_review_requirements.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:
jobs:
check-review-requirements:
name: "Check if a review is required from Connector teams"
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

if: ${{ github.event.pull_request.head.repo.fork == false }}
# This workflow cannot run on forks, as the fork's github token does not have `read:org`
Expand Down
29 changes: 17 additions & 12 deletions .github/workflows/format-fix-command.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ concurrency:

jobs:
format-fix:
name: "Run airbyte-ci format fix all"
runs-on: ubuntu-latest
name: "Run pre-commit fix"
runs-on: ubuntu-24.04
steps:
- name: Get job variables
id: job-vars
Expand Down Expand Up @@ -67,16 +67,21 @@ jobs:
[1]: ${{ steps.job-vars.outputs.run-url }}
- name: Run airbyte-ci format fix all
uses: ./.github/actions/run-airbyte-ci
continue-on-error: true
# Compare the below to the `format_check.yml` workflow
- name: Setup Java
uses: actions/setup-java@v3
with:
distribution: "zulu"
java-version: "21"
- name: Setup Python
uses: actions/setup-python@v5
with:
context: "manual"
gcs_credentials: ${{ secrets.METADATA_SERVICE_PROD_GCS_CREDENTIALS }}
sentry_dsn: ${{ secrets.SENTRY_AIRBYTE_CI_DSN }}
github_token: ${{ secrets.GH_PAT_MAINTENANCE_OCTAVIA }}
subcommand: "format fix all"
dagger_cloud_token: ${{ secrets.DAGGER_CLOUD_TOKEN_CACHE_2 }}
python-version: "3.10"
cache: "pip"
- name: Run pre-commit
uses: pre-commit/[email protected]
continue-on-error: true
id: format-fix

# This is helpful in the case that we change a previously committed generated file to be ignored by git.
- name: Remove any files that have been gitignored
Expand All @@ -87,7 +92,7 @@ jobs:
- name: Check for changes
id: git-diff
run: |
git diff --quiet && echo "No changes to commit" || echo "::set-output name=changes::true"
git diff --quiet && echo "No changes to commit" || echo "changes=true" >> $GITHUB_OUTPUT
shell: bash

# Commit changes (if any)
Expand Down
63 changes: 22 additions & 41 deletions .github/workflows/format_check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,61 +10,42 @@ on:

jobs:
format-check:
# IMPORTANT: This name must match the require check name on the branch protection settings
name: "Check for formatting errors"
# Do not run this job on forks
# Forked PRs are handled by the community_ci.yml workflow
if: github.event.pull_request.head.repo.fork != true
runs-on: tooling-test-small
runs-on: ubuntu-24.04
steps:
- name: Checkout Airbyte (with credentials)
uses: actions/checkout@v4
- uses: actions/checkout@v4
- name: Setup Java
uses: actions/setup-java@v3
with:
ref: ${{ github.head_ref }}
token: ${{ secrets.GH_PAT_APPROVINGTON_OCTAVIA }}
fetch-depth: 1
- name: Run airbyte-ci format check [MASTER]
id: airbyte_ci_format_check_all_master
if: github.ref == 'refs/heads/master'
uses: ./.github/actions/run-airbyte-ci
continue-on-error: true
distribution: "zulu"
java-version: "21"
- name: Setup Python
uses: actions/setup-python@v5
with:
context: "master"
sentry_dsn: ${{ secrets.SENTRY_AIRBYTE_CI_DSN }}
subcommand: "format check all"

- name: Run airbyte-ci format check [PULL REQUEST]
id: airbyte_ci_format_check_all_pr
if: github.event_name == 'pull_request'
uses: ./.github/actions/run-airbyte-ci
continue-on-error: false
with:
context: "pull_request"
sentry_dsn: ${{ secrets.SENTRY_AIRBYTE_CI_DSN }}
subcommand: "format check all"
dagger_cloud_token: ${{ secrets.DAGGER_CLOUD_TOKEN_CACHE_2 }}

- name: Run airbyte-ci format check [WORKFLOW DISPATCH]
id: airbyte_ci_format_check_all_manual
if: github.event_name == 'workflow_dispatch'
uses: ./.github/actions/run-airbyte-ci
continue-on-error: false
python-version: "3.10"
cache: "pip"
- name: Run pre-commit
uses: pre-commit/[email protected]
id: format-check
with:
context: "manual"
sentry_dsn: ${{ secrets.SENTRY_AIRBYTE_CI_DSN }}
subcommand: "format check all"
dagger_cloud_token: ${{ secrets.DAGGER_CLOUD_TOKEN_CACHE_2 }}
extra_args: --all-files

- name: Match GitHub User to Slack User [MASTER]
if: github.ref == 'refs/heads/master'
if: >
always() && steps.format-check.outcome == 'failure' &&
github.ref == 'refs/heads/master' &&
github.event.pull_request.head.repo.fork == false
id: match-github-to-slack-user
uses: ./.github/actions/match-github-to-slack-user
env:
AIRBYTE_TEAM_BOT_SLACK_TOKEN: ${{ secrets.SLACK_AIRBYTE_TEAM_READ_USERS }}
GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Format Failure on Master Slack Channel [MASTER]
if: steps.airbyte_ci_format_check_all_master.outcome == 'failure' && github.ref == 'refs/heads/master'
if: >
always() && steps.format-check.outcome == 'failure' &&
github.ref == 'refs/heads/master' &&
github.event.pull_request.head.repo.fork == false
uses: abinoda/slack-action@master
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN_AIRBYTE_TEAM }}
Expand Down
Loading

0 comments on commit 3f6ff97

Please sign in to comment.