Skip to content

[DOP-35394] Add descendants relations to hierarchy requests#423

Draft
TiGrib wants to merge 2 commits intodevelopfrom
feature/DOP-35394
Draft

[DOP-35394] Add descendants relations to hierarchy requests#423
TiGrib wants to merge 2 commits intodevelopfrom
feature/DOP-35394

Conversation

@TiGrib
Copy link
Copy Markdown
Contributor

@TiGrib TiGrib commented Mar 31, 2026

Change Summary

Change allgorithm of collecting job hierarchy. Now for each step we collect all ansectors and descendants.

Related issue number

[DOP-35394]

Checklist

  • Commit message and PR title is comprehensive
  • Keep the change as small as possible
  • Unit and integration tests for the changes exist
  • Tests pass on CI and coverage does not decrease
  • Documentation reflects the changes where applicable
  • docs/changelog/next_release/<pull request or issue id>.<change type>.rst file added describing change
    (see CONTRIBUTING.rst for details.)
  • My PR is ready to review.

@TiGrib TiGrib self-assigned this Mar 31, 2026
@github-actions
Copy link
Copy Markdown

Coverage

Coverage Report •
FileStmtsMissBranchBrPartCoverMissing
data_rentgen/server/services
   job.py6518098%81
TOTAL7936981124421687% 

@TiGrib TiGrib requested a review from dolfinus April 1, 2026 05:47
result.parents.update(await self._uow.job.list_ancestor_relations(ids))
result.parents.update(await self._uow.job.list_descendant_relations(ids))

# Collect all job nodes for the response
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's move this under else: block

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I understand moving under else: is not enough for correct collecting data I should use new variable level (simular to LineageService)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep

# Cover both inferred links connected to task0 and task4.
edge_task_ids = [tasks[0].id, tasks[4].id]
# Cover both inferred links connected to spark0 and spark4.
edge_task_ids = [sparks[0].id, sparks[4].id]
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
edge_task_ids = [sparks[0].id, sparks[4].id]
edge_spark_ids = [sparks[0].id, sparks[4].id]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants