-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[Extension] support .egg-info to store wheel type extension metadata #13286
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
[Extension] support .egg-info to store wheel type extension metadata #13286
Conversation
|
add to S170 |
| self.assertTrue(metadata['azext.isPreview']) | ||
| self.assertTrue(metadata['azext.isExperimental']) |
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.
I remember these two tags are not supposed to be both True in the future. @zhoxing-ms for confirmation.
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.
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.
Thanks for sharing this, I just learnt that.
I think the class WheelExtension and DevExtension is to represent data model not validation. Validation should be a higher level business.
This PR is about to test reading the metadata correctly, not validation for isExperimental and isPreview unless we decide to make validation here.
Please @jiasli make sure that the concern above has been made in CLI.
|
|
||
| ext_name, ext_version = 'hello', '0.1.0' | ||
|
|
||
| ext_extension = WheelExtension(ext_name, os.path.join(self.ext_dir, ext_name + '-' + ext_version)) |
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.
not use DevExtension?
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.
This is to test WheelExtension class not DevExtension.
The user using this way to develop Azure CLI extension is to hack the machenism. I think it's doable but not recommended. And supporting .egg-info is just one month ago.
Description
As this PR #12367 pointing out, some user may manually install extension from source code and still want to load it.
Same scenario could happen in the developing of azure-cli-ml as discussed offline. The develop CLI extension without azdev, and use that way to work in editable mode in older CLI (<= 2.4.0)
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 feature.
This 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.