Skip to content

[Proposal] Quality Gates - enforce lint/type-check before feature_mark_passing #96

Description

@cabana8471-arch

Related Issues

Problem

Currently, the agent can call feature_mark_passing without any verification that the code actually works. This leads to:

  1. Features marked as "passing" that don't compile - No lint/type-check enforcement
  2. No evidence of what was tested - We don't know if the agent actually verified the feature
  3. Features stuck in "in_progress" after agent crash - No auto-recovery mechanism
  4. No retry logic - If a feature fails, no tracking of failure count or reason

Proposed Solution

I've implemented "Quality Gates" in my fork that addresses all these issues:

1. Auto-detect Linters and Type Checkers

# Automatic detection based on project config files
Linters:    ESLint, Biome, ruff, flake8
Type-check: TypeScript (tsc), Python (mypy)

2. Enforce Quality Checks Before feature_mark_passing

# New MCP tool: feature_verify_quality
# Runs detected linters/type-checkers
# In strict mode, blocks marking if checks fail

3. Store Quality Results as Evidence

New database columns:

4. Auto-clear Stuck Features

On agent startup, features stuck in in_progress for >1 hour are reset to pending with failure tracking.

Implementation Details

  • ~400 lines in new quality_gates.py module
  • Small changes to feature_mcp.py (adds feature_verify_quality, feature_report_failure tools)
  • New DB columns (auto-migrated by SQLAlchemy)
  • Backwards compatible: disabled by default

Configuration

// .autocoder/config.json
{
  "quality_gates": {
    "enabled": true,
    "strict_mode": true,  // Block marking if checks fail
    "checks": {
      "lint": true,
      "type_check": true
    }
  }
}

Questions for Maintainers

  1. Would you be interested in this feature?
  2. Should strict_mode be the default, or should it just warn?
  3. Any concerns about adding DB columns for tracking?

Happy to submit a PR if there's interest. The implementation is already working in my fork.

Activity

  1. cabana8471-arch commented on Jan 26, 2026

    @cabana8471-arch
    ContributorAuthor

    Closing - this was a proposal that didn't move forward. The core problem (agent skipping tests) has been partially addressed by other fixes. May revisit in the future if there's interest.

  2. dengyier commented on Aug 16, 2026

    @dengyier

    Your Quality Gates proposal is closing the right hole: feature_mark_passing should only happen after real checks, not self-assertion. One deeper gap worth adding to that gate list — even when lint/type-check/tests all pass, the agent may have changed the test instead of the code. That failure mode is invisible to a gate that only checks "did the checks run".

    We've been building exactly that layer: bind the eligible population and a negative control (which must fail for the registered reason) into a verdict anyone can replay offline. Five-minute check — I changed one byte in a delivery that still says VERIFIED, and one command catches it: https://dev.to/dengyier/i-tampered-with-a-verified-ai-agent-delivery-can-you-find-it-in-5-minutes-4kp0

    If that direction is useful, happy to run a free verification report on one of your passing features so you can judge the output: https://dengyier.github.io/openworkproof-site/

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions