Skip to content

Commit ca4bf6a

Browse files
committed
Updates to yaml and python script documentation. Remove auto-merge feature until after team review.
1 parent 141b90c commit ca4bf6a

File tree

3 files changed

+23
-16
lines changed

3 files changed

+23
-16
lines changed

.github/dependabot.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,23 @@
33
# Please see the documentation for all configuration options:
44
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
55

6+
# This configuration will enable Dependabot version updates for all of our SDKs. It combines with the GitHub Action
7+
# workflow /.github/workflows/dependabot-update-external-deps.yml to maintain continuity with external_dependencies.txt
68
version: 2
79
updates:
810
- package-ecosystem: "maven" # See documentation for possible values
9-
directories:
10-
- "/sdk/*"
11+
directories:
12+
- "/sdk/*" # All pom files in the sdk directory
1113
schedule:
1214
interval: "daily"
1315
reviewers: ["jairmyree"]
1416
open-pull-requests-limit: 10
15-
ignore:
16-
- dependency-name: "*"
17+
ignore: # any specific dependencies or upgrade tupes that should be excluded from version updates
18+
- dependency-name: "*"
1719
update-types: ["version-update:semver-major"]
1820
- dependency-name: "org.apache.spark*"
1921
- dependency-name: "io.projectreactor*"
2022
- dependency-name: "com.fasterxml.jackson*"
2123
- dependency-name: "org.springframework*"
22-
23-
24+
25+

.github/workflows/dependabot-update-external-deps.yml

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# This workflow is triggered when a pull request is opened by Dependabot
2+
# This workflow will use metadata from Dependabot update to update external_dependencies.txt and update the dependency across all the SDKs
3+
# This workflow will auto-approve and merge the pull request if the update is a patch version or minor version update with a compatibility score of 80 or higher.
4+
5+
# NOTE: The auto-approved and merge step is currently disabled.
16
name: Dependabot Update External Dependencies
27
on: pull_request
38

@@ -10,7 +15,7 @@ permissions:
1015
jobs:
1116
dependabot:
1217
runs-on: ubuntu-latest
13-
if: github.event.pull_request.user.login == 'dependabot[bot]'
18+
if: github.event.pull_request.user.login == 'dependabot[bot]'
1419
steps:
1520
- name: Fetch Dependabot metadata
1621
id: dependabot-metadata
@@ -32,7 +37,7 @@ jobs:
3237
uses: actions/setup-python@v4
3338
with:
3439
python-version: '3.x'
35-
40+
3641
- name: Adjust External Dependencies
3742
run: python eng/versioning/dependabot_update_external_dependencies.py --json '${{steps.dependabot-metadata.outputs.updated-dependencies-json}}'
3843

@@ -50,12 +55,12 @@ jobs:
5055
env:
5156
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5257

53-
- name: Auto-Approve and Merge Pull Request
54-
if: ${{ steps.dependabot-metadata.outputs.update-type == 'version-update:semver-patch' || (steps.dependabot-metadata.outputs.update-type == 'version-update:semver-minor' && steps.dependabot-metadata.outputs.compatibility-score >= 80)}}
55-
run: |
56-
gh pr review --approve "${{ github.event.pull_request.html_url }}"
57-
gh pr merge "${{ github.event.pull_request.html_url }}" --auto --squash
58-
env:
59-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
58+
# - name: Auto-Approve and Merge Pull Request
59+
# if: ${{ steps.dependabot-metadata.outputs.update-type == 'version-update:semver-patch' || (steps.dependabot-metadata.outputs.update-type == 'version-update:semver-minor' && steps.dependabot-metadata.outputs.compatibility-score >= 80)}}
60+
# run: |
61+
# gh pr review --approve "${{ github.event.pull_request.html_url }}"
62+
# gh pr merge "${{ github.event.pull_request.html_url }}" --auto --squash
63+
# env:
64+
# GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6065

6166

eng/versioning/dependabot_update_external_dependencies.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Licensed under the MIT License.
33
"""
44
This script updates external dependencies in the `external_dependencies.txt` file based on the provided JSON input.
5-
It also runs another script `update_versions.py` to update versions.
5+
It also runs another script `update_versions.py` to update upgraded dependencies across all SDKs.
66
77
Usage:
88
python dependabot_update_external_dependencies.py --json '<json_string>'

0 commit comments

Comments
 (0)