Skip to content

Commit 6741f71

Browse files
committed
feat(FR-1881): enhance GitHub Copilot code review guidelines (#4965)
Resolves #4964 ([FR-1881](https://lablup.atlassian.net/browse/FR-1881)) ## Changes This PR enhances the GitHub Copilot code review guidelines by adding explicit instructions to prevent duplicate and redundant comments during code reviews. ### Key Updates 1. **What NOT to comment on** - New section with guidelines: - Avoid commenting on already resolved issues - Don't duplicate other reviewers' comments - Don't bundle unrelated issues in one comment 2. **Before commenting checklist** - Pre-review steps: - Check if issues were already addressed - Check if code was already fixed in recent commits - Check if other reviewers already mentioned the issue - Only comment if adding NEW value - Always check PR conversation history 3. **Formatting improvements** - Better document structure and readability ## Impact - Reduces review noise and redundant feedback - Improves reviewer efficiency - Creates more focused and valuable code review discussions - Helps maintain cleaner PR conversation threads [FR-1881]: https://lablup.atlassian.net/browse/FR-1881?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
1 parent 43e6f95 commit 6741f71

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

.github/copilot-instructions.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,12 @@ This file provides custom instructions for GitHub Copilot when reviewing code an
55
## Project Overview
66

77
Backend.AI WebUI is a **hybrid web application** with two main UI frameworks:
8+
89
- **Lit-Element Web Components** (`/src`) - Legacy UI components using TypeScript
910
- **React Components** (`/react`) - Modern UI components using React + Ant Design + Relay (GraphQL)
1011

1112
### Key Technologies
13+
1214
- **Build System**: Rollup for bundling, pnpm for package management
1315
- **Styling**: Ant Design (React), Material Web Components (Lit)
1416
- **State Management**: Redux (legacy), Relay (GraphQL for React)
@@ -20,11 +22,13 @@ Backend.AI WebUI is a **hybrid web application** with two main UI frameworks:
2022
### General Principles
2123

2224
1. **Avoid Unnecessary Suggestions**
25+
2326
- Do not suggest adding comments to code that is already self-explanatory
2427
- Focus on substantial issues (bugs, security vulnerabilities, performance problems)
2528
- Avoid stylistic nitpicks that don't affect code quality
2629

2730
2. **Security First**
31+
2832
- Always check for OWASP Top 10 vulnerabilities
2933
- Review for command injection, XSS, SQL injection risks
3034
- Validate user input handling and sanitization
@@ -34,9 +38,24 @@ Backend.AI WebUI is a **hybrid web application** with two main UI frameworks:
3438
- Use proper type inference when types are obvious
3539
- Leverage utility types (Pick, Omit, Partial, etc.)
3640

41+
### What NOT to comment on
42+
43+
1. **Do NOT comment on issues that have already been resolved** in the conversation thread
44+
2. **Do NOT duplicate comments** that other reviewers have already made
45+
3. **Do NOT bundle multiple unrelated issues** into a single review comment
46+
47+
### Before commenting
48+
49+
1. **Check if the issue was already addressed** in previous comments
50+
2. **Check if the code was already fixed** in recent commits
51+
3. **Check if another reviewer already mentioned** the same issue
52+
4. Only leave a comment if it adds **NEW value** to the review
53+
5. **Always check the PR conversation history** before commenting
54+
3755
### Architecture Awareness
3856

3957
When reviewing code:
58+
4059
- Recognize whether code is in `/src` (Lit-Element) or `/react` (React)
4160
- Understand the hybrid nature requires different patterns for each framework
4261
- Check that GraphQL queries use Relay conventions in React components
@@ -51,14 +70,17 @@ When reviewing code:
5170
## Git Workflow
5271

5372
### Commit Message Format
73+
5474
Follow conventional commit format:
75+
5576
- `feat(JIRA-ISSUE): description` - New features or enhancements
5677
- `fix(JIRA-ISSUE): description` - Bug fixes
5778
- `refactor(JIRA-ISSUE): description` - Code refactoring
5879
- `style(JIRA-ISSUE): description` - Design changes without functionality changes
5980
- `chore(JIRA-ISSUE): description` - Maintenance tasks
6081

6182
### PR Guidelines
83+
6284
- PR titles follow format: `prefix(JIRA-ISSUE-NUMBER): title`
6385
- PR description starts with: `Resolves #1234(FR-1234)`
6486
- Use **Squash merge** as default merge strategy

0 commit comments

Comments
 (0)