-
Notifications
You must be signed in to change notification settings - Fork 3.2k
{AI} Test GitHub Copilot PR review #31535
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
base: dev
Are you sure you want to change the base?
Conversation
️✔️AzureCLI-FullTest
|
Hi @zhoxing-ms, |
️✔️AzureCLI-BreakingChangeTest
|
Thank you for your contribution! We will review the pull request and get back to you soon. |
The git hooks are available for azure-cli and azure-cli-extensions repos. They could help you run required checks before creating the PR. Please sync the latest code with latest dev branch (for azure-cli) or main branch (for azure-cli-extensions). pip install azdev --upgrade
azdev setup -c <your azure-cli repo path> -r <your azure-cli-extensions repo path>
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This pull request introduces new test variables and helper changes in the VM module while updating help message texts. Key changes include adding temporary test variables (with inconsistent naming), a new test class with naming irregularities, and modifications to help messages for command arguments.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 6 comments.
File | Description |
---|---|
src/azure-cli/azure/cli/command_modules/vm/custom.py | Adds temporary test variables and a test class; naming issues present. |
src/azure-cli/azure/cli/command_modules/vm/_params.py | Updates help messages for command arguments with grammatical issues. |
@@ -154,6 +154,8 @@ def load_arguments(self, _): | |||
c.argument('network_access_policy', min_api='2020-05-01', help='Policy for accessing the disk via network.', arg_type=get_enum_type(self.get_models('NetworkAccessPolicy', operation_group=operation_group))) | |||
c.argument('disk_access', min_api='2020-05-01', help='Name or ID of the disk access resource for using private endpoints on disks.') | |||
c.argument('enable_bursting', arg_type=get_three_state_flag(), help='Enable on-demand bursting beyond the provisioned performance target of the disk. On-demand bursting is disabled by default, and it does not apply to Ultra disks.') | |||
c.argument('enable_bursting1', arg_type=get_three_state_flag(), help='Enables on-demand bursting beyond the provisioned performance target of the disk. On-demand bursting is disabled by default, and it does not apply to Ultra disks.') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Help message starts with 'Enables'; change it to the active, imperative form such as 'Enable on-demand bursting ...'.
c.argument('enable_bursting1', arg_type=get_three_state_flag(), help='Enables on-demand bursting beyond the provisioned performance target of the disk. On-demand bursting is disabled by default, and it does not apply to Ultra disks.') | |
c.argument('enable_bursting1', arg_type=get_three_state_flag(), help='Enable on-demand bursting beyond the provisioned performance target of the disk. On-demand bursting is disabled by default, and it does not apply to Ultra disks.') |
Copilot uses AI. Check for mistakes.
@@ -154,6 +154,8 @@ def load_arguments(self, _): | |||
c.argument('network_access_policy', min_api='2020-05-01', help='Policy for accessing the disk via network.', arg_type=get_enum_type(self.get_models('NetworkAccessPolicy', operation_group=operation_group))) | |||
c.argument('disk_access', min_api='2020-05-01', help='Name or ID of the disk access resource for using private endpoints on disks.') | |||
c.argument('enable_bursting', arg_type=get_three_state_flag(), help='Enable on-demand bursting beyond the provisioned performance target of the disk. On-demand bursting is disabled by default, and it does not apply to Ultra disks.') | |||
c.argument('enable_bursting1', arg_type=get_three_state_flag(), help='Enables on-demand bursting beyond the provisioned performance target of the disk. On-demand bursting is disabled by default, and it does not apply to Ultra disks.') | |||
c.argument('enable_bursting2', arg_type=get_three_state_flag(), help='Enabled on-demand bursting beyond the provisioned performance target of the disk. On-demand bursting is disabled by default, and it does not apply to Ultra disks.') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Help message starts with 'Enabled' (passive voice); use the active, imperative voice (e.g., 'Enable on-demand bursting ...').
c.argument('enable_bursting2', arg_type=get_three_state_flag(), help='Enabled on-demand bursting beyond the provisioned performance target of the disk. On-demand bursting is disabled by default, and it does not apply to Ultra disks.') | |
c.argument('enable_bursting2', arg_type=get_three_state_flag(), help='Enable on-demand bursting beyond the provisioned performance target of the disk. On-demand bursting is disabled by default, and it does not apply to Ultra disks.') |
Copilot uses AI. Check for mistakes.
@@ -389,7 +391,7 @@ def load_arguments(self, _): | |||
|
|||
with self.argument_context('vm availability-set create') as c: | |||
c.argument('availability_set_name', name_arg_type, validator=get_default_location_from_resource_group, help='Name of the availability set') | |||
c.argument('platform_update_domain_count', type=int, help='Update Domain count. If unspecified, the server will pick the most optimal number like 5.') | |||
c.argument('platform_update_domain_count', type=int, help='Updated Domain count. If unspecified, the server will pick the most optimal number like 5.') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Help message begins with 'Updated', which is not in the active, imperative voice; consider changing it to 'Update Domain count ...'.
c.argument('platform_update_domain_count', type=int, help='Updated Domain count. If unspecified, the server will pick the most optimal number like 5.') | |
c.argument('platform_update_domain_count', type=int, help='Update Domain count. If unspecified, the server will pick the most optimal number like 5.') |
Copilot uses AI. Check for mistakes.
i = 8808 | ||
j = 8809 | ||
test_port = 8810 | ||
testPort2 = 8811 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The variable 'testPort2' should follow snake_case naming; consider renaming it to 'test_port2'.
Copilot uses AI. Check for mistakes.
@@ -5977,3 +5982,8 @@ def list_vm_sizes(cmd, location): | |||
|
|||
|
|||
# endRegion | |||
|
|||
|
|||
class test_PR_review: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Class names should be in CamelCase; consider renaming 'test_PR_review' to 'TestPRReview'.
Copilot uses AI. Check for mistakes.
|
||
|
||
class test_PR_review: | ||
def testPPReviw(self): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Method names should use snake_case; consider renaming 'testPPReviw' to 'test_pp_review'.
Copilot uses AI. Check for mistakes.
Related command
Description
Testing Guide
History Notes
[Component Name 1] BREAKING CHANGE:
az command a
: Make some customer-facing breaking change[Component Name 2]
az command b
: Add some customer-facing featureThis checklist is used to make sure that common guidelines for a pull request are followed.
The PR title and description has followed the guideline in Submitting Pull Requests.
I adhere to the Command Guidelines.
I adhere to the Error Handling Guidelines.