microsoft / microsoft/azure-devops-python-api
Can get a task definition by id.
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 684
- Forks
- 218
- Avg merge
- 8d 10h
- Merged PRs (30d)
- 1
Description
Having a task definition reference by id it's not possibled to have it retrieved.
I'm reffering to TaskDefinitionReference which is present both in task_agent_client.pyand build_client.py.
For example getting a pipeline definition and having mutiple build steps like
{
'environment': {},
'enabled': True,
'continueOnError': False,
'alwaysRun': True,
'displayName': 'Publish Artifact',
'timeoutInMinutes': 0,
'condition': 'succeededOrFailed()',
'task': {
**'id': '2ff763a7-ce83-4e1f-bc89-0ae63477cebe',**
'versionSpec': '1.*',
'definitionType': 'task'
},
'inputs': {
'PathtoPublish': '$(build.artifactstagingdirectory)',
'ArtifactName': 'drop',
'ArtifactType': 'Container',
'TargetPath': '\\\\my\\share\\$(Build.DefinitionName)\\$(Build.BuildNumber)',
'Parallel': 'false',
'ParallelCount': '8',
'FileCopyOptions': ''
}
}
I would like to be able to retrieve all task step related by using the task -> id
Something like task_agent_client.get_task_by_id(task_id= '2ff763a7-ce83-4e1f-bc89-0ae63477cebe') and will return an object of type
class:TaskDefinitionReference <azure.devops.v5_1.task_agent.models.TaskDefinition>
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading TaskDefinitionReference in task_agent_client.py and build_client.py, then trace how pipeline task references are retrieved. Add the requested task_agent_client.get_task_by_id entry point so the task ID returns a TaskDefinition object, and verify the returned data against the example task reference.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, python
- Domain
- api, devops
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100