Skip to content

Fix missing install step in notebooks for documentation (Colab support) #2

Fix missing install step in notebooks for documentation (Colab support)

Fix missing install step in notebooks for documentation (Colab support) #2

Workflow file for this run

# Verifies if a pull request has at least one label from a set of valid
# labels before it can be merged.
#
# NOTE:
# This workflow may be triggered twice in quick succession when a PR is
# created:
# 1) `opened` — when the pull request is initially created
# 2) `labeled` — if labels are added immediately after creation
# (e.g. by manual labeling, another workflow, or GitHub App).
#
# These are separate GitHub events, so two workflow runs can be started.
name: PR labels check
on:
pull_request_target:
types: [opened, labeled, unlabeled, synchronize]
permissions:
pull-requests: read
jobs:
check-labels:
runs-on: ubuntu-latest
steps:
- name: Check for valid labels
run: |
PR_LABELS=$(echo '${{ toJson(github.event.pull_request.labels.*.name) }}' | jq -r '.[]')
echo "Current PR labels: $PR_LABELS"
VALID_LABELS=(
"[bot] release"
"[scope] bug"
"[scope] documentation"
"[scope] enhancement"
"[scope] maintenance"
"[scope] significant"
)
found=false
for label in "${VALID_LABELS[@]}"; do
if echo "$PR_LABELS" | grep -Fxq "$label"; then
echo "✅ Found valid label: $label"
found=true
break
fi
done
if [ "$found" = false ]; then
echo "ERROR: PR must have at least one of the following labels:"
for label in "${VALID_LABELS[@]}"; do
echo " - $label"
done
exit 1
fi