Skip to content
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

fix: Avoid triggering temporary dask-awkward/awkward incompatibility. #694

Conversation

jpivarski
Copy link
Member

dask-awkward assumes that ak.Array((1, 2, 3)) makes an ak.Array, the same as ak.Array([1, 2, 3]), which is a sensible assumption.

scikit-hep/awkward#1614 accidentally changed that, and while one accidental consequence was for the better (ak.from_iter({"one": 1, "two": 2, "three": 3}) no longer returns ak.Array(["one", "two", "three"])), it's reasonable to suppose that a top-level tuple is intended to become an ak.Array, especially if passed to the ak.Array constructor.

scikit-hep/awkward#1642 fixes it (best of both worlds), but Uproot tests would fail until this comes through. Therefore, this fix removes the tests that trigger the incompatibility. It should be merged into any Uproot PRs that are failing because of it.

Removing the len tests doesn't decrease the power of the test: assert_eq would not be satisfied if the lengths were different. However, it does reduce coverage of the dask-awkward __len__ code.

@jpivarski jpivarski enabled auto-merge (squash) August 29, 2022 17:37
@jpivarski jpivarski merged commit a1e54fc into main Aug 29, 2022
@jpivarski jpivarski deleted the jpivarski/avoid-triggering-temporary-dask-awkward-awkward-incompatibility branch August 29, 2022 18:08
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.

1 participant