Fix map_blocks not using own arguments in name generation#8462
Fix map_blocks not using own arguments in name generation#8462jrbourbeau merged 3 commits intodask:mainfrom
map_blocks not using own arguments in name generation#8462Conversation
jrbourbeau
left a comment
There was a problem hiding this comment.
Thanks @djhoese! I left one small comment about the tests that were added, but overall the changes here look good
gjoseph92
left a comment
There was a problem hiding this comment.
LGTM. The tests are a little more than I was expecting—I thought you'd only test that x.name changed with the different arguments—but I'm not sure if the other related behavior (chunks, dtype, drop_axis, new_axis) is insufficiently tested, so these extra tests are worthwhile.
That is what I'm doing here. Each of these arguments has an effect on the name so I wanted a test for each one, but also wanted to make sure that the functions were returning what was expected. I see what you're saying and I initially wanted to just add these I can simplify these tests if either of you would like me to. |
map_blocks not using own arguments in name generation
See #8450 for the full discussion. This PR adds (as suggested by @gjoseph92) the
map_blocksargument'schunks,dtype,new_axis, anddrop_axisto the call totokenizeso they are included as part of the result's name. Without this it is possible to get two results that should be treated differently by the scheduler but the scheduler won't know since they have the same name. I did verify that all of these tests fail without the fix.pre-commit run --all-files