Skip to content
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

chore: fix global PUT for task config policies #9941

Merged
merged 4 commits into from
Sep 18, 2024
Merged

Conversation

kkunapuli
Copy link
Contributor

@kkunapuli kkunapuli commented Sep 17, 2024

Ticket

CM-534

Description

Fix global PUT API for task config policies to include a parameter for the admin input.

Test Plan

None needed.

Checklist

  • Changes have been manually QA'd
  • New features have been approved by the corresponding PM
  • User-facing API changes have the "User-facing API Change" label
  • Release notes have been added as a separate file under docs/release-notes/
    See Release Note for details.
  • Licenses have been included for new code which was copied and/or modified from any external code

@cla-bot cla-bot bot added the cla-signed label Sep 17, 2024
Copy link

netlify bot commented Sep 17, 2024

Deploy Preview for determined-ui canceled.

Name Link
🔨 Latest commit 533275e
🔍 Latest deploy log https://app.netlify.com/sites/determined-ui/deploys/66e9ee6446d07b0008feff9a

Copy link

codecov bot commented Sep 17, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 54.50%. Comparing base (26b0954) to head (533275e).
Report is 8 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #9941      +/-   ##
==========================================
- Coverage   54.51%   54.50%   -0.01%     
==========================================
  Files        1252     1252              
  Lines      156668   156668              
  Branches     3601     3599       -2     
==========================================
- Hits        85411    85396      -15     
- Misses      71124    71139      +15     
  Partials      133      133              
Flag Coverage Δ
backend 45.16% <ø> (-0.03%) ⬇️
harness 72.75% <ø> (ø)
web 54.27% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

see 4 files with indirect coverage changes

@kkunapuli kkunapuli marked this pull request as ready for review September 17, 2024 17:20
@kkunapuli kkunapuli requested a review from a team as a code owner September 17, 2024 17:20
@kkunapuli kkunapuli requested review from corban-beaird, amandavialva01 and salonig23 and removed request for corban-beaird September 17, 2024 17:20
@@ -45,9 +57,14 @@ message PutGlobalConfigPoliciesResponse {
// GetWorkspaceConfigPoliciesRequest lists task config policies
// for a given workspace and workload type.
message GetWorkspaceConfigPoliciesRequest {
option (grpc.gateway.protoc_gen_swagger.options.openapiv2_schema) = {
json_schema: { required: [ "workload_type" ] }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is workspace_id also required here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great suggestion; I'll add it to all the workspace requests.

@@ -76,9 +97,14 @@ message GetGlobalConfigPoliciesResponse {
// DeleteWorkspaceConfigPoliciesRequest is used to delete all task config
// policies for the workspace and workload type.
message DeleteWorkspaceConfigPoliciesRequest {
option (grpc.gateway.protoc_gen_swagger.options.openapiv2_schema) = {
json_schema: { required: [ "workload_type" ] }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
json_schema: { required: [ "workload_type" ] }
json_schema: { required: [ "workload_type", "workspace_id" ] }

(maybe this?)

Copy link
Contributor

@amandavialva01 amandavialva01 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Left a few comments on required protobuf fields

Copy link
Contributor

@amandavialva01 amandavialva01 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, great work!

@kkunapuli kkunapuli merged commit d943d85 into main Sep 18, 2024
82 of 94 checks passed
@kkunapuli kkunapuli deleted the kunapuli/fix-global-get branch September 18, 2024 17:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants