Skip to content

Upgrade gradle dependencies only if >=48h old#11293

Open
sarahchen6 wants to merge 1 commit intomasterfrom
sarahchen6/implement-48h-cooldown-for-gradle-dependencies
Open

Upgrade gradle dependencies only if >=48h old#11293
sarahchen6 wants to merge 1 commit intomasterfrom
sarahchen6/implement-48h-cooldown-for-gradle-dependencies

Conversation

@sarahchen6
Copy link
Copy Markdown
Contributor

What Does This Do

Only upgrade gradle dependencies if they are at least 48 hours old. This PR specifically addresses the “Update Gradle dependencies” workflow. This follows #11215

Motivation

Require a 48-hour cooldown on external dependencies to reduce the risk of zero-day vulnerabilities.

Additional Notes

This PR was largely written by AI with my guidance on requirements and testing, followed by my review and tweaks for readability.

I added python tests for the scripts, but the actual changes need to land on master before the workflow can be tested because the workflow depends on an octo-sts token that is only scoped to master.

Contributor Checklist

Jira ticket: [PROJ-IDENT]

Note: Once your PR is ready to merge, add it to the merge queue by commenting /merge. /merge -c cancels the queue request. /merge -f --reason "reason" skips all merge queue checks; please use this judiciously, as some checks do not run at the PR-level. For more information, see this doc.

@sarahchen6 sarahchen6 added tag: no release notes Changes to exclude from release notes comp: tooling Build & Tooling tag: ai generated Largely based on code generated by an AI or LLM labels May 6, 2026
Base automatically changed from sarahchen6/implement-48h-cooldown to master May 6, 2026 23:48
@sarahchen6 sarahchen6 force-pushed the sarahchen6/implement-48h-cooldown-for-gradle-dependencies branch from 4efc512 to 5d9229e Compare May 7, 2026 13:00
@sarahchen6 sarahchen6 force-pushed the sarahchen6/implement-48h-cooldown-for-gradle-dependencies branch from 5d9229e to 355ced2 Compare May 7, 2026 13:02
@sarahchen6 sarahchen6 marked this pull request as ready for review May 7, 2026 14:04
@sarahchen6 sarahchen6 requested a review from a team as a code owner May 7, 2026 14:04
@sarahchen6 sarahchen6 requested review from AlexeyKuznetsov-DD and amarziali and removed request for a team May 7, 2026 14:04
@DataDog DataDog deleted a comment from dd-octo-sts Bot May 7, 2026
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 355ced273e

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines +330 to +332
if published_at is None:
print(f"::warning file={relative_path}::{gav}: {reason} Skipping age check.")
continue
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Enforce dependency-age policy when timestamp lookup fails

When resolve_gav_timestamp cannot determine a publish time, this branch only emits a warning and skips validation, so the updated lockfile is kept unchanged. In the current workflow (update-gradle-dependencies.yaml), no --metadata-file is provided, so any Maven Central outage/rate-limit or any dependency not indexed there will bypass the 48-hour gate entirely, which contradicts the stated policy of only upgrading dependencies old enough to pass the cooldown.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp: tooling Build & Tooling tag: ai generated Largely based on code generated by an AI or LLM tag: no release notes Changes to exclude from release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant