Skip to content

AGENTS.md and CODE_STYLE.md 2026 August update - #4148

Draft
cursor[bot] wants to merge 1 commit into
mainfrom
cursor/guardrails-august-2026
Draft

AGENTS.md and CODE_STYLE.md 2026 August update#4148
cursor[bot] wants to merge 1 commit into
mainfrom
cursor/guardrails-august-2026

Conversation

@cursor

@cursor cursor Bot commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Checklist

  • If applicable, unit tests
  • If applicable, create follow-up issues for purchases-ios and hybrids

Motivation

Monthly guardrails update based on PR review feedback analysis.

Description

Summary

Analyzed 1,187 comments across 243 pull requests from August 2026 (2026-08-01 to 2026-08-31) in RevenueCat/purchases-android. Comments came from 19 human reviewers (tonidero, AlvaroBrey, vegaro, rickvdl, facumenzella, peterporfy, ajpallares, polmiro, JayShortway, fire-at-will, JZDesign, MonikaMateska, TheRogue76, guillemcorominas, cyrilmottier, Climbatize, gurgen-k-y) and 4 bots (cursor[bot], copilot-pull-request-reviewer[bot], codecov[bot], emerge-tools[bot]).

New guidelines added

Guideline Why (PR review frequency)
RedundantJvmNameWithSynthetic detekt rule — Flags @JvmName on declarations already marked @JvmSynthetic (the latter hides the member from Java entirely, making @JvmName useless) Flagged 3+ times across admob-next-gen stack (PR #3985, #4015, #4028); reviewers caught leftover @JvmName annotations after Kotlin-only migration
Test every new code path (AGENTS.md) — Every behavior change or feature must include unit tests for new paths including error/null/edge cases 67 mentions across 38 PRs; the most frequent review request ("Needs a unit test?", "Should we have an integration test?", "no test that covers the null case")
iOS naming parity (AGENTS.md) — Match purchases-ios type and property names unless Kotlin conventions require otherwise 29 mentions across 14 PRs; reviewers repeatedly asked "Should we rename Info to Context?", "Let's standardize this", cross-platform naming drift
KDoc only for non-obvious behavior (AGENTS.md) — Omit KDoc that restates the signature; only document preconditions, side effects, and non-obvious semantics 10+ mentions across 9 PRs; reviewers flagged "do we need this comment at all? the code is self-explanatory", "this is more text than reading the actual function"

Test plan

  • ./gradlew :detekt-rules:test — all 12 tests pass (4 new for RedundantJvmNameWithSynthetic + 8 existing)
  • ./gradlew detektAll — passes with zero violations (no existing code matches the new rule)
  • No baseline additions required
Open in Web View Automation 

…26 code style updates

- New custom detekt rule: RedundantJvmNameWithSynthetic
  Flags @JvmName on declarations already marked @JvmSynthetic, since
  @JvmSynthetic hides the member from Java entirely.
- AGENTS.md Code Style: Test every new code path
- AGENTS.md Code Style: iOS naming parity
- AGENTS.md Code Style: KDoc only for non-obvious behavior

Co-authored-by: Cesar de la Vega <vegaro@users.noreply.github.com>
@vegaro vegaro added the pr:other label Sep 1, 2026 — with Cursor
@codecov

codecov Bot commented Sep 1, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 83.50%. Comparing base (337ea5e) to head (3d00e4f).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4148   +/-   ##
=======================================
  Coverage   83.50%   83.50%           
=======================================
  Files         451      451           
  Lines       18146    18146           
  Branches     2737     2737           
=======================================
  Hits        15152    15152           
  Misses       2106     2106           
  Partials      888      888           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants