Scheduling infrastructure for absolutely everyone.
fix: switch conflict resolver from push to schedule trigger to save runner costs (#26690)
Keith Williams46b1bc3365bf
diff --git a/.github/workflows/devin-conflict-resolver.yml b/.github/workflows/devin-conflict-resolver.ymlindex cf48112cfdf..b649869d7d3 100644--- a/.github/workflows/devin-conflict-resolver.yml+++ b/.github/workflows/devin-conflict-resolver.yml@@ -1,9 +1,11 @@name: Devin PR Conflict Resolveron:- push:- branches:- - main+ # Run every 5 minutes instead of on push to main.+ # This saves runner costs by avoiding the 20-second sleep that was needed+ # to wait for GitHub to compute mergeable status after merges to main.+ schedule:+ - cron: '*/5 * * * *'workflow_dispatch:inputs:pr_number:@@ -152,10 +154,7 @@ jobs:}if (unknownPRs.length > 0) {- console.log(`\n${unknownPRs.length} PRs have UNKNOWN mergeable status, waiting 20 seconds before retrying...`);- await new Promise(resolve => setTimeout(resolve, 20000));-- console.log(`Retrying ${unknownPRs.length} PRs via REST API...`);+ console.log(`\n${unknownPRs.length} PRs have UNKNOWN mergeable status, retrying via REST API...`);for (const pr of unknownPRs) {try {@@ -181,7 +180,7 @@ jobs:conflictingPRs.push(result.data);if (result.isTargetPR) break;} else if (result.unknown) {- console.log(`PR #${pr.number} still has UNKNOWN status after retry`);+ console.log(`PR #${pr.number} still has UNKNOWN status, will be checked on next run`);}} catch (error) {console.error(`Error retrying PR #${pr.number}: ${error.message}`);