devopshq / tfs

Microsoft TFS API Python client
https://devopshq.github.io/tfs/
MIT License
110 stars 28 forks source link

get Changeset from Workteim #79

Open cmedcoff opened 4 years ago

cmedcoff commented 4 years ago

I have the following code (fragment):

client = TFSAPI(server_url=bh_tfs_base_url, project=collection, user=user, password=password, auth_type=HttpNtlmAuth)
px = client.run_query("Shared Queries/PX Queries/PX - Priority List")
for work_item in px.result.workitems:
    change_sets_relation = work_item.find_in_relation("ArtifactLink")
    for changeset_relation in change_sets_relation:

How to I create a Changetset object from the relation pointing to the changeset?

SAnCherepan commented 4 years ago

@cmedcoff, changeset_obj = Changeset(client, changeset_relation) should work. Try it out and let me know if it works out for you.