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

refactor: removed the 'ak._util.extra' argument helper. #1955

Merged
merged 2 commits into from
Dec 6, 2022

Conversation

jpivarski
Copy link
Member

@jpivarski jpivarski commented Dec 6, 2022

It was a vestige of Python 2: as you can see, we can express the keyword-only arguments after a *arrays without any trouble in Python 3. This is relevant because the documentation will be generated with more information now—these extra arguments and their defaults will appear in the HTML rendering of the function signatures.

Also, ak.broadcast_arrays was missing information about its broadcast_parameters_rule argument. Presumably, that was an oversight? (And it demonstrates the problem with ak._util.extra.)


📚 The documentation for this PR will be available at https://awkward-array.readthedocs.io/en/jpivarski-remove-extra-argument-helper/ once Read the Docs has finished building 🔨

@jpivarski jpivarski self-assigned this Dec 6, 2022
@jpivarski jpivarski added the pr-next-release Required for the next release label Dec 6, 2022
Comment on lines +25 to +33
broadcast_parameters_rule (str): Rule for broadcasting parameters, one of:
- `"intersect"`
- `"all_or_nothing"`
- `"one_to_one"`
- `"none"`
left_broadcast (bool): If True, follow rules for implicit
left-broadcasting, as described below.
right_broadcast (bool): If True, follow rules for implicit
right-broadcasting, as described below.
Copy link
Collaborator

Choose a reason for hiding this comment

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

I swear we had this at one point. Maybe it never made it to the final PR 😦

@codecov
Copy link

codecov bot commented Dec 6, 2022

Codecov Report

Merging #1955 (6506c42) into main (86471d3) will decrease coverage by 0.00%.
The diff coverage is 100.00%.

Additional details and impacted files
Impacted Files Coverage Δ
src/awkward/_util.py 81.00% <ø> (-0.15%) ⬇️
src/awkward/operations/ak_broadcast_arrays.py 100.00% <100.00%> (ø)
src/awkward/operations/ak_where.py 91.66% <100.00%> (-0.18%) ⬇️

@agoose77 agoose77 enabled auto-merge (squash) December 6, 2022 00:26
@agoose77 agoose77 merged commit 8253722 into main Dec 6, 2022
@agoose77 agoose77 deleted the jpivarski/remove-extra-argument-helper branch December 6, 2022 00:27
@jpivarski jpivarski removed the pr-next-release Required for the next release label Feb 15, 2023
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.

2 participants