-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Removed custom_object.py and created a new file namespaced_custom_object.py which is more specific to usage of namespaced custom resource #1440
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
Conversation
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: roycaihw, Yashks1994 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/release-note-none |
|
Git takes renaming of the file with name
To reflect the deletion of file
Ok, I misunderstood the file renaming with the file deletion part. The file renaming would look something like this in the PR's Sorry for the trouble. (And I learnt this new thing. :) ) |
3d09481 to
0a1c73c
Compare
|
@roycaihw needs your /lgtm as CI build passed. |
@Priyankasaggu11929 I was surprised when I saw that the first time. I didn't expect Github to render it that way but it's really beautiful. @Yashks1994 LGTM. Please squash the commits as I suggested in #1439 (comment):
|
2482a33 to
f8c37d3
Compare
f8c37d3 to
a5cee19
Compare
| # patch the namespaced custom object to update the `spec.cronSpec` field | ||
| patch_resource = api.patch_namespaced_custom_object( | ||
| # delete it | ||
| api.delete_namespaced_custom_object( |
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.
why do we have a commit that reverse the order of patch_namespaced_custom_object and delete_namespaced_custom_object?
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.
https://github.com/kubernetes-client/python/pull/1444/commits is what I was asking for, if that makes sense
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 kept the order like this,
we have create, get, patch, delete
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.
currently the two PRs have the same code change, but the commits are different
Commits should represent meaningful milestones or units of work. Currently the commits in this PR are:
- your first commit renames the file and adds a patch method after the delete method, which means the example has a bug and will run into an error
- your second commit reverses the order of the patch method and the delete method to fix the bug in the first commit
please take a look at https://github.com/kubernetes/community/blob/master/contributors/guide/github-workflow.md#squash-commits. The second commit is a "Work in progress" (it fixes a bug in the first commit during development), so please squash it.
again, I think having two commits like the following will be most reasonable and readable:
- one commit for adding patch example to custom_object.py
- one commit for renaming the file to namespaced_custom_object.py
at this point I'm also okay with having just one commit, which will be more reasonable than the current two commits in this PR
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 am keeping the one commit and with proper commit message.
d3ea959 to
3d48709
Compare
|
@Yashks1994: Cannot trigger testing until a trusted user reviews the PR and leaves an In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
3d48709 to
9248a90
Compare
|
Thanks! |

What type of PR is this?
/kind cleanup
/kind documentation
What this PR does / why we need it:
Removed the custom_object.py and created a new file as namespaced_custom_object.py which is more specific to usage of namespaced custom resource.
Which issue(s) this PR fixes:
Fixes #1438