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 configuration of breaks when using recent scales package. #140

Merged
merged 3 commits into from
Jan 16, 2025

Conversation

plietar
Copy link
Contributor

@plietar plietar commented Feb 19, 2024

Closes #144
Closes #143

The latest release of the scales package has added a pair of optional arguments, d_transform and d_inverse, in the middle of the parameter list for trans_new (see r-lib/scales#341). As a consequence, this has shifted the position of the breaks parameter from 4th to 6th.

Because the bench_time_trans and bench_bytes_trans functions from this package were passing in the breaks object positionally, this change in the scales package means that the breaks object is now matched with the new d_transform formal parameter and it ends up being ignored.

This commit changes the arguments to trans_new from being positional to being named, which should be more robust to future changes to the function.

plietar and others added 2 commits January 16, 2025 11:21
The latest release of the scales package has added a pair of optional
arguments, `d_transform` and `d_inverse`, in the middle of the parameter
list for `trans_new` (see r-lib/scales#341). As
a consequence, this has shifted the position of the `breaks` parameter
from 4th to 6th.

Because the `bench_time_trans` and `bench_bytes_trans` functions from
this package were passing in the breaks object positionally, this change
in the scales package means that the breaks object is now matched with
the new `d_transform` formal parameter and it ends up being ignored.

This commit changes the arguments to `trans_new` from being positional
to being named, which should be more robust to future changes to the
function.
@DavisVaughan DavisVaughan merged commit 3dd50d7 into r-lib:main Jan 16, 2025
11 checks passed
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.

scale_*_bench_*() functions obscure lower values
2 participants