Skip to content

Conversation

@djkirkham
Copy link
Contributor

This is a workaround for dask/dask#2823 (now fixed on dask/master), identified in #2861.

@djkirkham djkirkham mentioned this pull request Oct 27, 2017
@cpelley
Copy link

cpelley commented Oct 27, 2017

Is it worth adding a test that captures current dask behaviour? That way, when it fails (iris uses a dask release with the fix), it will be obvious to remove the workaround. Or alternatively a known failure test.

@djkirkham
Copy link
Contributor Author

@cpelley That makes sense

self.assertMaskedArrayEqual(result, a)

def test_dask_scalar_proxy_pass_through(self):
# This test will fail when using a version of Dask with
Copy link
Member

Choose a reason for hiding this comment

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

A little bit naughty (hello future person who is going back and reading this PR).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hello

res = ma.masked_array(res.data, mask=res.mask)
return res

_getall_delayed = dask.delayed(_getall)
Copy link
Member

Choose a reason for hiding this comment

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

There is a decorator for this purpose...

@pelson pelson added this to the v2.0.0 milestone Oct 27, 2017
@pelson pelson merged commit 5bfb85e into SciTools:master Oct 27, 2017
@djkirkham djkirkham deleted the fix_lazy_scalar branch October 27, 2017 16:20
@djkirkham djkirkham mentioned this pull request Mar 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants