From 0596e888d27b36c368c5caede495ba643a82dcc6 Mon Sep 17 00:00:00 2001 From: Nicolas Schweitzer Date: Wed, 12 Feb 2025 11:49:48 +0100 Subject: [PATCH 1/3] feat(check_for_changes): Direct release managers ping --- tasks/libs/pipeline/notifications.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tasks/libs/pipeline/notifications.py b/tasks/libs/pipeline/notifications.py index 5193e219660a61..35175c7609dec2 100644 --- a/tasks/libs/pipeline/notifications.py +++ b/tasks/libs/pipeline/notifications.py @@ -191,6 +191,11 @@ def warn_new_commits(release_managers, team, branch, next_rc): message += f":announcement: We detected new commits on the {branch} release branch of `integrations-core`.\n" message += f"Could you please release and tag your repo to prepare the {next_rc} `datadog-agent` release candidate planned <{rc_schedule_link}|{rc_date.strftime('%Y-%m-%d %H:%M')}> UTC?\n" message += "Thanks in advance!\n" - message += f"cc {' '.join(release_managers)}" client = WebClient(os.environ["SLACK_API_TOKEN"]) + slack_ids = [] + for email in release_managers: + r = client.users_lookupByEmail(email=email) + if r.status_code == 200: + slack_ids.append(r.data["user"]["id"]) + message += f"cc {' '.join(f'<@{sid}>' for sid in slack_ids)}" client.chat_postMessage(channel=f"#{team}", text=message) From a3a4c8cd3dae4a62201323030c95848ee84d240b Mon Sep 17 00:00:00 2001 From: Nicolas Schweitzer Date: Wed, 12 Feb 2025 10:22:28 +0100 Subject: [PATCH 2/3] fix(renovate):Add depedencies label and fix the protoc regex to allow rc --- renovate.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/renovate.json b/renovate.json index f855658382127d..e8446d31e923ab 100644 --- a/renovate.json +++ b/renovate.json @@ -1,5 +1,6 @@ { "$schema": "https://docs.renovatebot.com/renovate-schema.json", + "labels": ["dependencies"], "enabledManagers": ["custom.regex"], "customManagers" : [ { @@ -18,7 +19,7 @@ "customType": "regex", "fileMatch": [".protoc-version"], "matchStrings": [ - "(?[0-9]+.[0-9]+)" + "(?[0-9]+.[0-9]+(-rc[0-9]+)?)" ], "depNameTemplate": "protoc", "versioningTemplate": "loose", From d68adccb7b4e01daf56ff4e87a1763b62211c6a4 Mon Sep 17 00:00:00 2001 From: Nicolas Schweitzer Date: Wed, 12 Feb 2025 14:49:11 +0100 Subject: [PATCH 3/3] add omnibus-ruby manager and attributes to test the config --- renovate.json | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/renovate.json b/renovate.json index e8446d31e923ab..5f3e8a90638978 100644 --- a/renovate.json +++ b/renovate.json @@ -2,6 +2,8 @@ "$schema": "https://docs.renovatebot.com/renovate-schema.json", "labels": ["dependencies"], "enabledManagers": ["custom.regex"], + "baseBranches": ["main", "nschweitzer/renovate"], + "useBaseBranchConfig": "merge", "customManagers" : [ { "customType": "regex", @@ -24,6 +26,16 @@ "depNameTemplate": "protoc", "versioningTemplate": "loose", "datasourceTemplate": "custom.protoc" + }, + { + "customType": "regex", + "fileMatch": ["release.json"], + "matchStrings": [ + "[ ]+\"OMNIBUS_RUBY_VERSION\": \"(?[a-z0-9]+)\"" + ], + "depNameTemplate": "omnibus-ruby", + "versioningTemplate": "loose", + "datasourceTemplate": "custom.omnibus-ruby" } ], "customDatasources": { @@ -38,6 +50,12 @@ "transformTemplates": [ "{\"releases\": $map($.[tag_name,published_at], function($v) { {\"version\": $v[0], \"releaseTimestamp\": $v[1] } }) }" ] + }, + "omnibus-ruby": { + "defaultRegistryUrlTemplate": "https://api.github.com/repos/datadog/omnibus-ruby/commits", + "transformTemplates": [ + "{\"releases\": $map($.[sha,commit.author.date], function($v) { {\"version\": $v[0], \"releaseTimestamp\": $v[1] } }) }" + ] } } }