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: remove unused keyword arg #2046

Merged
merged 1 commit into from
Dec 30, 2022
Merged

fix: remove unused keyword arg #2046

merged 1 commit into from
Dec 30, 2022

Conversation

agoose77
Copy link
Collaborator

#1968 added the redundant return_simplified argument to ak.transform. I missed it in my initial review, but it doesn't do anything and should be removed. I think we can do this immediately; the option isn't documented, and doesn't do anything.

@codecov
Copy link

codecov bot commented Dec 30, 2022

Codecov Report

Merging #2046 (8e2f4e1) into main (64377c1) will not change coverage.
The diff coverage is n/a.

Additional details and impacted files
Impacted Files Coverage Δ
src/awkward/operations/ak_transform.py 91.30% <ø> (ø)

@agoose77 agoose77 temporarily deployed to docs-preview December 30, 2022 17:43 — with GitHub Actions Inactive
Copy link
Member

@jpivarski jpivarski left a comment

Choose a reason for hiding this comment

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

Oops!

You're right: that's a relic of a partial implementation. At first, return_array and return_simplified were to be two booleans, but two booleans have 4 possible values and only 3 of them would have been meaningful, so I combined them into a single enumerated argument, return_value.

The return_simplified is left over from having implemented it the one way, changing my mind, and implementing it the other way without completely cleaning up.

It is possible for someone to depend on it the same way as the last change in arguments: someone could be uselessly passing an argument through a wrapper of transform, which would then fail if an argument of this name disappears. However, this is much less likely than in the previous case, since transform is a new function and it's too low-level to be a dask-awkward function. So I agree that we can try silently removing it.

I approve this PR for merging.

@agoose77 agoose77 merged commit 17fea95 into main Dec 30, 2022
@agoose77 agoose77 deleted the agoose77-patch-1 branch December 30, 2022 18:26
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.

None yet

2 participants