cf-python-client icon indicating copy to clipboard operation
cf-python-client copied to clipboard

Optional `suspended` Parameter Causes TypeError When Updating Organization

Open geigerj0 opened this issue 2 months ago • 0 comments

Problem

Calling the organization update API without passing a suspended parameter raises a TypeError about a missing required positional argument, even though suspended is Optional:

https://github.com/cloudfoundry-community/cf-python-client/blob/54274723906dd92500d7f18b4b22689ad7cdd660/cloudfoundry_client/v3/organizations.py#L23

Example

Using the client like so

cf_client.v3.organizations.update(org_guid, org_name, meta_labels={"foo": "bar"})

Results in

TypeError: OrganizationManager.update() missing 1 required positional argument: 'suspended'

Potential Solution

Could assign None to the optional be the fix of the problem?

suspended: Optional[bool] = None,

geigerj0 avatar Nov 04 '25 14:11 geigerj0