This is an automated email from the ASF dual-hosted git repository.
hez pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git
The following commit(s) were added to refs/heads/main by this push:
new 34589301e fix: Exclude all non-job timeline entries from collection
(#5075)
34589301e is described below
commit 34589301e0776e8fa92a2b4bbdf04c8d9e32b2a1
Author: Camille Teruel <[email protected]>
AuthorDate: Tue May 2 20:36:12 2023 +0200
fix: Exclude all non-job timeline entries from collection (#5075)
Co-authored-by: Camille Teruel <[email protected]>
---
backend/python/plugins/azuredevops/azuredevops/streams/jobs.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/backend/python/plugins/azuredevops/azuredevops/streams/jobs.py
b/backend/python/plugins/azuredevops/azuredevops/streams/jobs.py
index 131739551..49676d97a 100644
--- a/backend/python/plugins/azuredevops/azuredevops/streams/jobs.py
+++ b/backend/python/plugins/azuredevops/azuredevops/streams/jobs.py
@@ -32,8 +32,9 @@ class Jobs(Substream):
api = AzureDevOpsAPI(context.connection)
response = api.jobs(repo.org_id, repo.project_id, parent.id)
for raw_job in response.json["records"]:
- raw_job["build_id"] = parent.domain_id()
- yield raw_job, state
+ if raw_job["type"] == "Job":
+ raw_job["build_id"] = parent.domain_id()
+ yield raw_job, state
def convert(self, j: Job, ctx: Context) -> Iterable[devops.CICDPipeline]:
result = None