Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Regression: patch_namespaced_custom_object only accepts merge-patch+json patch type #2119

Closed as not planned
@mwgamble

Description

@mwgamble

What happened (please include outputs or screenshots):

According to #862, this library is supposed to support JSON Patch in patch_namespaced_custom_object(), not just JSON Merge Patch. As far as I can tell, this is not the case:

header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/merge-patch+json']) # noqa: E501

What you expected to happen:

I should be able to specify that I want to use JSON Patch with this method.

How to reproduce it (as minimally and precisely as possible):

Attempt to supply an array of JSON Patch objects and observe that you receive an unsupported media type error.

Anything else we need to know?:

Environment:

  • Kubernetes version (kubectl version): 1.24
  • OS (e.g., MacOS 10.13.6): Linux 5.15 LTS kernel
  • Python version (python --version) 3.10.9
  • Python client version (pip list | grep kubernetes) 24.2.0

Metadata

Metadata

Assignees

Labels

kind/bugCategorizes issue or PR as related to a bug.lifecycle/rottenDenotes an issue or PR that has aged beyond stale and will be auto-closed.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions