teamcity icon indicating copy to clipboard operation
teamcity copied to clipboard

parameter field_name not required for tc.build_type_api.change_requirement_setting

Open MNSEhub opened this issue 1 year ago • 0 comments

Hi,

As seen here: build_type_api.change_requirement_setting this function requires an parameter field_name, which must not be used at all for the function. All values for it other than "" (empty str) leads to an error, as the parameter is currently mandatory by validation, but must be always "" to build the correct url for the underlying TC RestAPI call.

To use this function at it's current state, it needs to be called as (using dohq-teamcity Types below):

bt: BuildType
ar: AgentRequirement

api_response = tc.build_type_api.change_requirement_setting(bt, ar, "", body=ar)

The parameter should be removed.

Thanks and Cheers --- mnse

MNSEhub avatar Jun 05 '24 08:06 MNSEhub