AOSSIE-Org / AOSSIE-Org/Template-Repo

Config: Add Additional path_filters to .coderabbit.yaml to Reduce Review Noise

Đang mở
#96 2 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
YAML
Star
17
Fork
29
Merge trung bình
3 ngày 13 giờ
Pull request đã merge (30 ngày)
6

Mô tả

## Overview

The current `.coderabbit.yaml` already excludes some paths from CodeRabbit reviews, but several common noise sources are not yet filtered. Adding more targeted `path_filters` will reduce unnecessary review churn on auto-generated, vendored, or non-reviewable files.

---

## Proposed Change

Extend the `path_filters` section in `.coderabbit.yaml` with the following exclusions:

```yaml
path_filters:
# --- Minified / compiled assets ---
- "!**/*.min.js" # Minified JavaScript (not human-authored)
- "!**/*.min.css" # Minified CSS (not human-authored)
- "!**/*.bundle.js" # Bundled JS output
- "!**/*.map" # Source maps

# --- Vendored dependencies ---
- "!**/vendor/**" # Go vendor directory
- "!**/node_modules/**" # Node.js dependencies (usually already excluded)

# --- Database / ORM migration files ---
- "!**/migrations/**" # Auto-generated migration files (Django, Alembic, Flyway, etc.)
- "!**/db/schema.rb" # Rails auto-generated schema

# --- Python cache ---
- "!**/__pycache__/**" # Python bytecode cache
- "!**/*.pyc" # Compiled Python files
- "!**/*.pyo" # Optimized Python files

# --- Lockfiles ---
- "!**/poetry.lock" # Poetry lockfile
- "!**/Pipfile.lock" # Pipenv lockfile
- "!**/yarn.lock" # Yarn lockfile
- "!**/pnpm-lock.yaml" # pnpm lockfile
- "!**/Cargo.lock" # Rust lockfile (for non-library crates, review may be wanted)

# --- Generated / build artifacts ---
- "!**/dist/**" # Build output directories
- "!**/build/**" # Build output directories
- "!**/.next/**" # Next.js build output
- "!**/*.pb.go" # Protobuf-generated Go files
- "!**/*_generated.go" # Other Go generated files
- "!**/*.generated.ts" # Generated TypeScript files
```

---

## Rationale

| Filter | Reason |
|---|---|
| Minified assets | Machine-generated; reviewing them adds no value |
| Vendor / node_modules | Third-party code; not owned by contributors |
| Migration files | Auto-generated by ORMs; schema intent is reviewed via model changes |
| Python cache | Binary/compiled; not reviewable |
| Lockfiles | Exact versions are managed by package managers; dependency changes are reviewed via manifest files |
| Build artifacts | Machine-generated output; not part of source authorship |
| Protobuf / generated files | Auto-generated from source specs; review the `.proto` or generator config instead |

---

## Acceptance Criteria

- [ ] `.coderabbit.yaml` updated with the additional `path_filters` entries.
- [ ] Verified that legitimate source files are not accidentally excluded.
- [ ] The `template-sync.yml` workflow propagates the updated config to child repos using this template.

---

## References

- CodeRabbit path filters documentation: https://docs.coderabbit.ai/guides/review-instructions
- CodeRabbit YAML template reference: https://docs.coderabbit.ai/reference/yaml-template/

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.