-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add another test for fork within fork wrapped in join #73
Conversation
Codecov Report
@@ Coverage Diff @@
## dev #73 +/- ##
==========================================
+ Coverage 81.83% 82.27% +0.43%
==========================================
Files 37 37
Lines 881 897 +16
Branches 107 108 +1
==========================================
+ Hits 721 738 +17
+ Misses 160 159 -1
Continue to review full report at Codecov.
|
52905bb
to
d76bb9f
Compare
multiple forks inside other forks were also fixed in this commit. |
Tests for junction inside fork and fork inside fork (either wrapped in join or not) were added to check the shape of graph. This was performed by counting the length of the graphson array for vertices and for edges. I am aware that this is far from ideal but it is a quick way to check if something is broken in the near future. These tests must be re-worked after refactoring the pipeline object to something that can be run before execution. |
@tiagofilipe12 delete branch? |
This PR fixes an issue with fork inside fork. Avoids the duplication of outermost tasks when fork is not nested in a join inside a fork. Previously this was not being properly handled because there was no way to check whether outermost tasks where the same as downstream tasks.
The rational is when fork is inside fork without join wrapping, outermost tasks will be the same as downstream tasks and thus should not be added to
lineage
twice. On the other hand when join is wrapping the inner fork, outermost tasks (after outer fork) are different from downstream tasks (after inner fork) and thus both should be added tolineage
.To achieve the comparison of these two arrays (
outermostTasks
anddownstreamTasks
) I have made two hashes for each by adding the individual hashes of each task within each one of these arrays, where these hashes are made withtask.info.operationCreator
. So, when all tasks inside both arrays have the sameoperationCreator
it will return the same hash, otherwise they will be different.Then was just a matter of checking if both hashes are equal or not.