-
Notifications
You must be signed in to change notification settings - Fork 212
Create Work Item failed because of type can not be replaced in url #259
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
Comments
Same issue here, with the following stack trace: Really tried several things to fix this issue, yet none found. |
Thanks for reporting, fixed in #258 |
/_apis/wit/workItems/${type}
When I call create work item, type is not replaced by the parameter
KeyError Traceback (most recent call last)
in
----> 1 work_item_client.create_work_item(document=document, project='Cognitive Services', type='Task')
~\AppData\Local\Continuum\anaconda3\lib\site-packages\azure\devops\released\work_item_tracking\work_item_tracking_client.py in create_work_item(self, document, project, type, validate_only, bypass_rules, suppress_notifications, expand)
1082 query_parameters=query_parameters,
1083 content=content,
-> 1084 media_type='application/json-patch+json')
1085 return self._deserialize('WorkItem', response)
1086
~\AppData\Local\Continuum\anaconda3\lib\site-packages\azure\devops\client.py in _send(self, http_method, location_id, version, route_values, query_parameters, content, media_type, accept_media_type, additional_headers)
75 location_id=location_id,
76 route_values=route_values,
---> 77 query_parameters=query_parameters)
78 negotiated_version = self._negotiate_request_version(
79 self._get_resource_location(location_id),
~\AppData\Local\Continuum\anaconda3\lib\site-packages\azure\devops\client.py in _create_request_message(self, http_method, location_id, route_values, query_parameters)
130 logger.debug('Route template: %s', location.route_template)
131 print(url)
--> 132 request = ClientRequest(method=http_method, url=self._client.format_url(url))
133 if query_parameters:
134 request.format_parameters(query_parameters)
~\AppData\Local\Continuum\anaconda3\lib\site-packages\msrest\service_client.py in format_url(self, url, **kwargs)
149 :param str url: The request URL to be formatted if necessary.
150 """
--> 151 url = url.format(**kwargs)
152 parsed = urlparse(url)
153 if not parsed.scheme or not parsed.netloc:
KeyError: 'type'
The text was updated successfully, but these errors were encountered: