Title: Failed to call method "create_test_run" in azure python api · Issue #520 · microsoft/azure-devops-python-api · GitHub
Open Graph Title: Failed to call method "create_test_run" in azure python api · Issue #520 · microsoft/azure-devops-python-api
X Title: Failed to call method "create_test_run" in azure python api · Issue #520 · microsoft/azure-devops-python-api
Description: Hi, i have a problem wih azure's python api. I self written function in python which calls official api from microscoft. def create_test_run(self, a_project_name: str = None, a_comment: str = None, a_test_run_name: str = None, a_error_ms...
Open Graph Description: Hi, i have a problem wih azure's python api. I self written function in python which calls official api from microscoft. def create_test_run(self, a_project_name: str = None, a_comment: str = None,...
X Description: Hi, i have a problem wih azure's python api. I self written function in python which calls official api from microscoft. def create_test_run(self, a_project_name: str = None, a_comment: str = N...
Opengraph URL: https://github.com/microsoft/azure-devops-python-api/issues/520
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Failed to call method \"create_test_run\" in azure python api","articleBody":"Hi, i have a problem wih azure's python api. I self written function in python which calls official api from microscoft.\n\n\n```\ndef create_test_run(self,\n a_project_name: str = None,\n a_comment: str = None,\n a_test_run_name: str = None,\n a_error_msg: str = None,\n a_test_run_points=None,\n a_test_plan=None\n ) -\u003e TestRun:\n \"\"\"create_test_run\n :param str a_project_name: the name of the azure project where your test_plans are located\n :param str a_comment: a comment that shall be added to the newly created test run\n :param str a_test_run_name: the name of the test_run that shall be created\n :param str a_error_msg: an error message for this test_run that can be displayed in azure\n :param str a_test_run_points: a list of point_ids that reference azure TestPlan \u003c-\u003e TestSuite \u003c-\u003e TestCase relation\n :param :class:`ShallowReference \u003cazure.devops.v5_1.microsoft._team_foundation._test_management._web_api.models.ShallowReference\u003e` a_test_plan: the test_plan for which this test_run shall be created\n :rtype: :class:`\u003cTestRun\u003e \u003cazure.devops.v5_1.test_results.models.TestRun\u003e`\n \"\"\"\n if None in (a_project_name, a_test_run_name, a_test_run_points, a_test_plan):\n raise InputError(\n f\"cannot create test_run in azure with a_project_name={a_project_name}, a_test_run_name={a_test_run_name}, a_test_run_points={a_test_run_points}, a_test_plan={a_test_plan}\")\n\nself. LOGGER.debug(\n f\"[create_test_run] creating create_test_run[{a_test_run_name}]\")\n\ntest_run = RunCreateModel(automated=False,\n comment=a_comment,\n name=a_test_run_name,\n error_message=a_error_msg,\n plan=a_test_plan,\n point_ids=a_test_run_points\n # build=builds.value[0] #TODO: check if we can add a build :class:`ShallowReference \u003cazure.devops.v5_1.microsoft._team_foundation._test_management._web_api.models.ShallowReference\u003e`\n )\n return self.connection.clients_v5_1.get_test_results_client().create_test_run(test_run=test_run, project=a_project_name)\n```\n\n\nEvery time we send this request, it gives a 404 error back, that the ressource does not exist. After looking carefully into the microscofts python api carefully i saw something. The function create_test_run in https://github.com/microsoft/azure-devops-python-api/blob/dev/azure-devops/azure/devops/v7_1/test_results/test_results_client.py only exists in the branches with a version number like dev5.1 and dev7.1. In the branch which is called dev, this function exists in another location which is https://github.com/microsoft/azure-devops-python-api/blob/dev/azure-devops/azure/devops/v7_1/test/test_client.py and the location ids are not identical. I would be very grateful if you can take a closer look to these source files.\n\nThank you and best regards,\n\nDaniel","author":{"url":"https://github.com/IAVDaniel","@type":"Person","name":"IAVDaniel"},"datePublished":"2025-03-31T06:38:05.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/520/azure-devops-python-api/issues/520"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:66083777-a1cc-7ec3-d6c4-8885fd082597 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | C46A:3CAE76:10E2FD0:16A330F:697D11A9 |
| html-safe-nonce | 1a62f133cab469b139720aedd8a391d0c3d506b15945a3a6ad202b516489e499 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDNDZBOjNDQUU3NjoxMEUyRkQwOjE2QTMzMEY6Njk3RDExQTkiLCJ2aXNpdG9yX2lkIjoiODM0MDIyMDU1NjYxNTY4NDUyMSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | a8451da23565e48f9575f7bfe82ac90198b77caeb255c8b4bb8d9f649972de68 |
| hovercard-subject-tag | issue:2959598099 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/microsoft/azure-devops-python-api/520/issue_layout |
| twitter:image | https://opengraph.githubassets.com/af047e5a38cd8c09b741e8d002d20f0e2819a61521469ba57c4186888124dca5/microsoft/azure-devops-python-api/issues/520 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/af047e5a38cd8c09b741e8d002d20f0e2819a61521469ba57c4186888124dca5/microsoft/azure-devops-python-api/issues/520 |
| og:image:alt | Hi, i have a problem wih azure's python api. I self written function in python which calls official api from microscoft. def create_test_run(self, a_project_name: str = None, a_comment: str = None,... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | IAVDaniel |
| hostname | github.com |
| expected-hostname | github.com |
| None | f4270289760ed79c539b4df0bf901fb752ee16d6a98c6589b1c6b6d5d4e1a000 |
| turbo-cache-control | no-preview |
| go-import | github.com/microsoft/azure-devops-python-api git https://github.com/microsoft/azure-devops-python-api.git |
| octolytics-dimension-user_id | 6154722 |
| octolytics-dimension-user_login | microsoft |
| octolytics-dimension-repository_id | 107710074 |
| octolytics-dimension-repository_nwo | microsoft/azure-devops-python-api |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 107710074 |
| octolytics-dimension-repository_network_root_nwo | microsoft/azure-devops-python-api |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 7add7da55b3463f73608a5dd149b156c4e76f2b8 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width