ci: "fix: exempt team members from compliance cleanup" (#28865)

This commit is contained in:
Aiden Cline
2026-05-22 11:14:52 -05:00
committed by GitHub
parent 00038027c8
commit 8596967415
6 changed files with 31 additions and 56 deletions

View File

@@ -15,11 +15,8 @@ const cutoff = new Date(Date.now() - days * 24 * 60 * 60 * 1000)
type Issue = {
number: number
updated_at: string
author_association: string
}
const teamAssociations = new Set(["OWNER", "MEMBER", "COLLABORATOR"])
const headers = {
Authorization: `Bearer ${token}`,
"Content-Type": "application/json",
@@ -66,10 +63,6 @@ async function main() {
for (const i of all) {
const updated = new Date(i.updated_at)
if (updated < cutoff) {
if (teamAssociations.has(i.author_association)) {
console.log(`Skipping #${i.number}: author association is ${i.author_association}`)
continue
}
stale.push(i.number)
} else {
console.log(`\nFound fresh issue #${i.number}, stopping`)