Skip to content

fix: honor the S3 profile name and file and Hadoop's addressing mode for custom endpoints #1622

fix: honor the S3 profile name and file and Hadoop's addressing mode for custom endpoints

fix: honor the S3 profile name and file and Hadoop's addressing mode for custom endpoints #1622

Workflow file for this run

# Licensed to the Apache Software Foundation (ASF) under one

Check warning on line 1 in .github/workflows/label_prs.yml

View workflow run for this annotation

GitHub Actions / Label pull requests

Workflow execution policy warning (evaluate mode)

On November 2, 2026, GitHub will restrict `pull_request_target` on public repositories by default. To continue allowing the event trigger, configure an Actions policy. Learn more: https://gh.io/securely-using-pull_request_target#default-policy-for-pull_request_target
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
name: Label pull requests
# Runs on pull_request_target so it can label pull requests from forks. Nothing from the pull
# request is checked out or executed: the labeler reads the changed file list through the API
# and the title step reads the event payload.
on:
pull_request_target:
types: [opened, synchronize, reopened]
permissions:
contents: read
pull-requests: write
# One group per pull request with cancellation, so at most one run writes labels at a time:
# the labeler action reads the label set and writes it back whole, and two runs writing at
# once can drop a label the other just added. A cancelled or replaced run loses nothing
# because every step below is safe to repeat on the next event.
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number }}
cancel-in-progress: true
jobs:
label:
runs-on: ubuntu-slim
steps:
# Checks out the base branch, never the pull request's code: under pull_request_target the
# default ref is the base commit, and only dev/ci/pr-type-label.mjs is read from it.
- uses: actions/checkout@v7
with:
persist-credentials: false
# The type label follows the conventional commit prefix in the title, matching how
# maintainers label by hand. The decision reads the pull request's current labels, not the
# event payload, so a type label a maintainer applied before this run started stays and
# a run cut short by a newer push is completed by that push. Dependabot pull requests
# already carry their label.
- name: Label by title prefix
if: github.actor != 'dependabot[bot]'
uses: actions/github-script@v9
with:
script: |
const { typeLabelsToAdd } = await import(
`${process.env.GITHUB_WORKSPACE}/dev/ci/pr-type-label.mjs`
);
const { data: current } = await github.rest.issues.listLabelsOnIssue({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
per_page: 100,
});
const labels = typeLabelsToAdd(
context.payload.pull_request.title,
current.map((label) => label.name),
);
if (labels.length === 0) {
core.info('No type label to add');
return;
}
await github.rest.issues.addLabels({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
labels,
});
- name: Label by changed paths
uses: actions/labeler@v7
with:
configuration-path: .github/labeler.yml
sync-labels: false