Skip to content

Add promise default fallback rule#18

Closed
benvinegar wants to merge 4 commits intomainfrom
autoresearch/new-strong-ai-rule-2026-04-07
Closed

Add promise default fallback rule#18
benvinegar wants to merge 4 commits intomainfrom
autoresearch/new-strong-ai-rule-2026-04-07

Conversation

@benvinegar
Copy link
Copy Markdown
Member

Summary

  • add the new defensive.promise-default-fallbacks rule for promise .catch() handlers that suppress rejections with cheap sentinel defaults or empty handlers
  • register the rule in the default registry and document it in a new rule README plus the main README rule list
  • add focused tests for the new rule and keep the existing heuristic/fixture regression coverage green
  • include the full pinned benchmark artifacts and autoresearch notes showing the rule's strong full-set benchmark signal

Benchmark signal

  • full pinned benchmark signal score: 0.9773662551440329
  • best separating metric: findings / file (0.9876543209876543)
  • hit rate: 9/9 AI repos vs 4/9 mature OSS repos
  • full report: reports/autoresearch-candidate-rule.md

Validation

  • bun test tests/heuristics.test.ts tests/promise-default-fallbacks.test.ts tests/rule-signal-benchmark.test.ts
  • bun test tests/fixtures-regression.test.ts tests/benchmark.test.ts
  • bun run lint

This PR description was generated by Pi using GPT-5

@benvinegar benvinegar force-pushed the autoresearch/new-strong-ai-rule-2026-04-07 branch from 007b187 to 8a13417 Compare April 19, 2026 14:45
@benvinegar
Copy link
Copy Markdown
Member Author

Closing as superseded.

The useful parts of this PR have already landed on main through later merged work, including the per-rule benchmark infrastructure and the defensive.promise-default-fallbacks rule itself. After rebasing this branch onto current main, it is now effectively empty relative to main, so there is no remaining merge delta here.

This comment was generated by Pi using GPT-5 Codex

@benvinegar benvinegar closed this Apr 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant