-
Notifications
You must be signed in to change notification settings - Fork 10
Add code owners #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1,2 @@ | ||
| /samples/ @pontemonti @rahuldevikar761 @JimDaly | ||
| # This will eventually be replaced by security group | ||
| * @rahuldevikar761 @pontemonti @juliomenendez @nikhilNava | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,67 @@ | ||
| # GitHub Copilot Instructions for Agent365-python | ||
|
|
||
| ## Code Review Rules | ||
|
|
||
| ### Rule 1: Check for "Kairo" Keyword | ||
| - **Description**: Scan code for any occurrence of the keyword "Kairo" | ||
| - **Action**: If "Kairo" is found in any code file: | ||
| - Flag it for review | ||
| - Suggest removal or replacement with appropriate terminology | ||
| - Check if it's a legacy reference that needs to be updated | ||
| - **Files to check**: All `.py` files in the repository | ||
|
|
||
| ### Rule 2: Verify Copyright Headers | ||
| - **Description**: Ensure all Python files have proper Microsoft copyright headers | ||
| - **Action**: If a `.py` file is missing a copyright header: | ||
| - Add the Microsoft copyright header at the top of the file | ||
| - The header should be placed before any imports or code | ||
| - Maintain proper formatting and spacing | ||
|
|
||
| #### Required Copyright Header Format | ||
| ```python | ||
| # Copyright (c) Microsoft Corporation. | ||
| # Licensed under the MIT License. | ||
| ``` | ||
|
|
||
| ### Implementation Guidelines | ||
|
|
||
| #### When Reviewing Code: | ||
| 1. **Kairo Check**: | ||
| - Search for case-insensitive matches of "Kairo" | ||
| - Review context to determine if it's: | ||
| - A variable name | ||
| - A comment reference | ||
| - An import statement | ||
| - A string literal | ||
| - Suggest appropriate alternatives based on the context | ||
|
|
||
| 2. **Header Check**: | ||
| - Verify the first non-empty, non-shebang lines of Python files | ||
| - If missing, prepend the copyright header | ||
| - Ensure there's a blank line after the header before other content | ||
| - Do not add headers to: | ||
| - `__init__.py` files that are intentionally empty | ||
| - Generated files (if marked as such) | ||
|
|
||
| #### Example of Proper File Structure: | ||
| ```python | ||
| # Copyright (c) Microsoft Corporation. | ||
| # Licensed under the MIT License. | ||
|
|
||
| """Module docstring goes here.""" | ||
|
|
||
| import os | ||
| import sys | ||
|
|
||
| # Rest of the code... | ||
| ``` | ||
|
|
||
| ### Auto-fix Behavior | ||
| When Copilot detects violations: | ||
| - **Kairo keyword**: Suggest inline replacement or flag for manual review | ||
| - **Missing header**: Automatically suggest adding the copyright header | ||
|
|
||
| ### Exclusions | ||
| - Test files in `tests/` directory may have relaxed header requirements (but headers are still recommended) | ||
| - Third-party code or vendored dependencies should not be modified | ||
| - Configuration files (`.toml`, `.json`, `.yaml`, `.md`) do not require Python copyright headers |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.