Skip to content

[Code Quality] Optimize skipped session timeout behavior in workflows #13245

@github-actions

Description

@github-actions

Description

21 skipped workflow sessions are consuming an average of 24.77 minutes each for no-op outcomes, representing significant resource waste. This represents 518 minutes (8.6 hours) of compute time per day that produces no value.

Current State

  • Skipped sessions: 21 of 50 total (42%)
  • Average duration: 24.77 minutes per skipped session
  • Total waste: ~518 minutes per analysis period
  • Pattern: Consistent timeout durations (18-31 minutes)
  • Impact: Resources consumed for conditional workflow skips

Root Cause

Conditional workflows that determine skip status are waiting full timeout periods instead of exiting early when skip condition is detected.

Suggested Changes

Implement early exit detection for conditional workflow skips:

  1. Add conditional check before expensive operations

    • Check skip conditions early in workflow execution
    • Exit immediately when conditions indicate skip
  2. Reduce default timeout for conditional workflows

    • Current: 30+ minute timeouts
    • Proposed: 5 minute timeout with early exit
  3. Add skip signal to workflow outputs

    • Workflows can signal skip intent to orchestrator
    • Orchestrator can cancel waiting workflows

Files Affected

  • .github/workflows/*.md - Conditional workflow files with skip logic
  • pkg/workflow/compiler.go - Add early exit detection in compiled workflows
  • Workflow orchestration logic for skip handling

Success Criteria

  • Skipped sessions complete in < 2 minutes
  • Resource consumption reduced by ~80% for skipped workflows
  • No impact on non-skipped workflow execution
  • All workflow tests pass

Source

Extracted from Daily Copilot Agent Session Analysis - 2026-02-02

Quote from report:

Long-Running Skipped Sessions: Efficiency concern

  • Issue: 21 skipped sessions averaged 24.77 minutes each
  • Pattern: Consistent timeout durations (18-31 minutes)
  • Impact: Significant resource consumption for no-op outcomes

Recommendation from report:

Optimize Skipped Session Timeout Behavior

  • Potential impact: High
  • Issue: 21 sessions consuming 24.77 minutes each for skipped outcomes
  • Recommendation: Implement early exit detection for conditional workflow skips

Priority

High - Significant resource waste (518 minutes/day). High impact optimization with clear measurable benefit.

Benefits

  • Resource savings: ~518 minutes per day (8.6 hours)
  • Faster feedback: Users know skip outcome in < 2 minutes
  • Cost reduction: Lower compute costs for conditional workflows
  • Better metrics: Clearer separation of skip vs. execution time

AI generated by Discussion Task Miner - Code Quality Improvement Agent

  • expires on Feb 16, 2026, 9:16 AM UTC

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions