azure-cli-extensions icon indicating copy to clipboard operation
azure-cli-extensions copied to clipboard

Add Python3 CLI Commands

Open sushil490023 opened this issue 3 years ago • 8 comments


This checklist is used to make sure that common guidelines for a pull request are followed.

Related command

General Guidelines

  • [ ] Have you run azdev style <YOUR_EXT> locally? (pip install azdev required)
  • [ ] Have you run python scripts/ci/test_index.py -q locally?

For new extensions:

About Extension Publish

There is a pipeline to automatically build, upload and publish extension wheels.
Once your pull request is merged into main branch, a new pull request will be created to update src/index.json automatically.
The precondition is to put your code inside this repository and upgrade the version in the pull request but do not modify src/index.json.

sushil490023 avatar Oct 04 '22 06:10 sushil490023

Thank you for your contribution sushil490023! We will review the pull request and get back to you soon.

ghost avatar Oct 04 '22 06:10 ghost

automation

yonzhan avatar Oct 04 '22 09:10 yonzhan

/azp run

wangzelin007 avatar Oct 07 '22 06:10 wangzelin007

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Oct 07 '22 06:10 azure-pipelines[bot]

@sushil490023 Could you please resolve those CI issues?

zhoxing-ms avatar Oct 09 '22 03:10 zhoxing-ms

@sushil490023, What is the difference between python3_package and python3package directories? Actually I compare the two directories and they use almost the same code. image

wangzelin007 avatar Oct 09 '22 05:10 wangzelin007

@sushil490023, May I ask if these example codes are automatically generated by codegen? If these extra blanks are caused by codegen, we should let @kairu-ms known about this. image

wangzelin007 avatar Oct 09 '22 05:10 wangzelin007

@sushil490023, May I ask if these example codes are automatically generated by codegen? If these extra blanks are caused by codegen, we should let @kairu-ms known about this. image

Examples are manually written in Workspace Editors right now.

kairu-ms avatar Oct 09 '22 06:10 kairu-ms

@sushil490023, What is the difference between python3_package and python3package directories? Actually I compare the two directories and they use almost the same code. image

I have deleted python3package directories

sushil490023 avatar Oct 18 '22 06:10 sushil490023

vcr.errors.CannotOverwriteExistingCassetteException: Can't overwrite existing cassette ('/mnt/vss/_work/1/s/src/automation/azext_automation/tests/latest/recordings/test_automation_software_update_configuration.yaml') in your current record mode ('once'). No match for the request (<Request (GET) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/westus/publishers/Canonical/artifacttypes/vmimage/offers/UbuntuServer/skus/18.04-LTS/versions?$top=1&$orderby=name%20desc&api-version=2022-08-01>) was found. Found 1 similar requests with 1 different matcher(s) :

1 - (<Request (GET) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/westus/publishers/Canonical/artifacttypes/vmimage/offers/UbuntuServer/skus/18.04-LTS/versions?$top=1&$orderby=name%20desc&api-version=2022-03-01>). Matchers succeeded : ['method', 'scheme', 'host', 'port', 'path'] Matchers failed : _custom_request_query_matcher - assertion failure : None

@sushil490023 This is because the api-version of Compute RP in azure-cli-core has been upgraded (PR link: https://github.com/Azure/azure-cli/pull/24036), so you need to re-record the tests related to Compute RP in the extension.

Please pull the latest main CLI code from the dev branch of Azure/azure-cli repo first, and re-record those failed tests locally and then pushing them into this PR

zhoxing-ms avatar Oct 18 '22 07:10 zhoxing-ms

Could you add some examples for command group automation hrwg ?

zhoxing-ms avatar Oct 20 '22 06:10 zhoxing-ms

Could you add some examples for command group automation hrwg ?

https://github.com/Azure/azure-cli-extensions/tree/main/src/automation#readme

sushil490023 avatar Oct 20 '22 09:10 sushil490023

Could you add some examples for command group automation hrwg ?

In fact, I mean adding examples to the help message of this command, such as https://github.com/Azure/azure-cli-extensions/pull/5415#discussion_r990729906

zhoxing-ms avatar Oct 20 '22 10:10 zhoxing-ms

Could you add some examples for command group automation hrwg ?

In fact, I mean adding examples to the help message of this command, such as #5415 (comment)

Updated

sushil490023 avatar Oct 20 '22 11:10 sushil490023

Please add the description of PR changes in the HISTORY.rst. And if you want to release a new extension version for this PR, please also upgrade the version defined in setup.py.

zhoxing-ms avatar Oct 21 '22 02:10 zhoxing-ms

Please add the description of PR changes in the HISTORY.rst. And if you want to release a new extension version for this PR, please also upgrade the version defined in setup.py.

Updated

sushil490023 avatar Oct 21 '22 06:10 sushil490023

@sushil490023, May I ask you to add some scenario tests for those new commands?

  • az automation hrwg update
  • az automation hrwg hrw create/delete/show/update

wangzelin007 avatar Oct 21 '22 08:10 wangzelin007

@microsoft-github-policy-service agree [company="Microsoft"]

sushil490023 avatar Oct 21 '22 08:10 sushil490023

@microsoft-github-policy-service agree [company="Microsoft"]

sushil490023 avatar Oct 21 '22 08:10 sushil490023

@microsoft-github-policy-service agree company="Microsoft"

wangzelin007 avatar Oct 21 '22 08:10 wangzelin007

May I ask you to add some scenario tests for those new commands?

az automation hrwg update az automation hrwg hrw create/delete/show/update

@sushil490023 Since these commands are existing commands, you may can consider submitting a PR separately to supplement these test cases. So we can merge the PR first, and then review the PR for supplementing test cases. What do you think of it?

zhoxing-ms avatar Oct 21 '22 08:10 zhoxing-ms

May I ask you to add some scenario tests for those new commands?

az automation hrwg update az automation hrwg hrw create/delete/show/update

@sushil490023 Since these commands are existing commands, you may can consider submitting a PR separately to supplement these test cases. So we can merge the PR first, and then review the PR for supplementing test cases. What do you think of it?

Yes i think that would be much helpful and i will create sperate PR for adding scenario test cases for left over test cases of Hybrid runbook worker

sushil490023 avatar Oct 21 '22 08:10 sushil490023

@microsoft-github-policy-service agree company="Microsoft"

sushil490023 avatar Oct 21 '22 08:10 sushil490023

@microsoft-github-policy-service agree

wangzelin007 avatar Oct 21 '22 08:10 wangzelin007

Force skip license/cla checks to merge this PR. @sushil490023, I think you still need to fix the account issue, otherwise every PR of yours will have to force skip checks to merge.

wangzelin007 avatar Oct 25 '22 07:10 wangzelin007

[Release] Update index.json for extension [ automation ] : https://dev.azure.com/azclitools/internal/_build/results?buildId=11062&view=results

azclibot avatar Oct 25 '22 07:10 azclibot