-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Containerapp 0.3.8 Release #5026
Conversation
Containerapp |
* init containerapp version 0.3.7 * Use PATCH API for containerapp update. * Removed double lines. * fix bug * Fix microsoft/azure-container-apps#261 * Fixed issue where containerapp up would not honor --registry-server. (#128) * Fixed issue where containerapp up would not honor --registry-server. * Updated history. Co-authored-by: Haroon Feisal <[email protected]> * bug fix * add tests * fix credscan suppressions * Use constant for acr registry prefix. * Fixed multi-container issue. * Removed comment. * Updated update_containerapp_yaml to use patch. Fixed minor style errors. * Fixed merge conflicts. * Rerecorded necessary tests. * Updated history. * Auto-populate secret values if passed without values. * Fixed bug where the containerapp had no secrets. Co-authored-by: Silas Strawn <[email protected]> Co-authored-by: Haroon Feisal <[email protected]>
…to ci suppressions. Reran tests. (#135) Co-authored-by: Haroon Feisal <[email protected]>
* Fixed yaml breaking change and bug where revision suffix would return invalid if user is adding a container and the previous revision has a revision suffix. * Fixed revision suffix yaml bug. Co-authored-by: Haroon Feisal <[email protected]>
Validate containerapp name.
Fix log stream bug
@zhoxing-ms when you are online today could you review this please, we would like to get this payload released soon. Thanks! |
Unrelated to changes on this PR , however, want to understand this code. |
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.
a few Qs/ comments in the chat. @haroonf / @StrawnSC please check. Thanks!
@calvinsID please review the changes as well, esp. the update using PATCH. Thanks! |
@panchagnula looks like this is needed since we're not using the SDK. The SDK automatically ignores readonly attributes that are set on a model before serializing it. @calvinsID is that right? (I believe you authored that part if I'm not mistaken since it's in the yaml command) |
Yeah this is needed since not using SDK. These properties shouldn't be passed into any PUT/PATCH api, but these properties are introduced from deserialization where normally SDK handles it |
is_valid = is_valid and '--' not in name | ||
name = name.replace('-', '') | ||
is_valid = is_valid and name.isalnum() | ||
is_valid = is_valid and name[0].isalpha() | ||
if not is_valid: | ||
raise ValidationError(f"Invalid Container App name {name}. A name must consist of lower case alphanumeric characters or '-', start with an alphabetic character, and end with an alphanumeric character and cannot have '--'. The length must not be more than 32 characters.") | ||
raise ValidationError(f"Invalid Container App name {name}. A name must consist of lower case alphanumeric characters or '-', start with an alphabetic character, and end with an alphanumeric character and cannot have '--'. The length must not be more than {MAXIMUM_CONTAINER_APP_NAME_LENGTH} characters.") | ||
|
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.
seems like the message is copied from portal ;) but "alphabetic character" seems incorrect English to me.
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 message is copied from the API
@StrawnSC - some of my comments are still not completely addressed - ex. adding comments to the helper library, explaining the need for those . & update help for container app name parameter, so that the format requirements are displayed in help docs? |
return d | ||
|
||
|
||
def _populate_secret_values(containerapp_def, secret_values): |
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.
@haroonf , don't need to change this logic for now, since we need to release the fix.
Can you help me understand the behavior in CLI with YAML here , when CLI parses the YAML with secretName & no value, does the payload to the API translate this object in JSON payload just name property & no value i.e{ name: xyz} or. {name: xyz, value: null}. if it is the former is the PATCH API, setting the value to null or is it cleaning these up because CLI explicitly passes null?
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 deserialization process leaves the json payload to {name: xyz, value: null}. The API returns an error "cannot set secret values to null."
@panchagnula Sorry about that - I must have misread your comment on the help text. Just pushed those changes. @haroonf can you take a look at Sisira's comment above |
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.
LGTM - please do update the comments if possible in this one. & answer the pending Qs
@zhoxing-ms could you take a look at this when you get the chance? We've had some customers asking about these fixes for a while |
This checklist is used to make sure that common guidelines for a pull request are followed.
Related command
General Guidelines
azdev style <YOUR_EXT>
locally? (pip install azdev
required)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
.