CI Auto-Fix

Automatically fix CI failures on your pull requests.

Overview

CI auto-fix is designed for validation failures that are visible from logs and can be corrected with a focused repository change.

CI auto-fix loop
01 Webhook event

Failure Event

A check run, pipeline, or status signal turns the branch red.

02 Diagnosis

Inspect Logs

Forkline gathers the failing context, logs, and likely reproduction clues.

03 Repair

Generate Fix

The agent changes code or configuration to address the root cause.

04 Feedback

Report Back

A follow-up commit or comment explains what changed.

CI auto-fix only starts after a provider reports a failed validation event on the branch.

Info: CI auto-fix requires webhook events for CI status such as check runs, pipeline events, or status updates.

Supported CI Sources

Forkline works with any CI system that reports the right webhook signals, including:

  • GitHub Actions
  • GitLab CI
  • Forgejo Actions
  • External CI systems that emit supported status events

Enabling CI Auto-Fix

  1. Navigate to Repositories
  2. Find your repository
  3. Click Settings on the repository card
  4. Select the Automation tab
  5. Find CI Auto-Fix
  6. Set the mode to Enable
  7. Set Maximum fix attempts per PR
  8. Click Save

What It Usually Fixes Well

  • Linting errors
  • Type errors
  • Straightforward test failures
  • Build errors such as missing imports or syntax issues

What Usually Needs Manual Intervention

  • Complex failures that require product or business logic decisions
  • Architecture-level problems
  • Multi-file refactors without a clear local fix
  • Infrastructure issues outside the repository
  • External service failures

Result Comments

Starting

🔧 CI Auto-Fix started

Detected failure in GitHub Actions workflow "Test".
Analyzing logs and generating fix...

Attempt 1/3

Success

✅ CI Auto-Fix completed

Fixed issue in src/utils/validation.ts:
- Updated email regex to reject consecutive dots
- Added test case for invalid email format

Commit: abc1234

Next Steps