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 a minor deprecated warning about trans arg #6202

Merged

Conversation

yutannihilation
Copy link
Member

I see this warning.

> devtools::test(filter = "binned")
ℹ Testing ggplot2
✔ | F W  S  OK | Context
✔ |   1     15 | scale-binned                                                                                
─────────────────────────────────────────────────────────────────────────────────────────────────────────────
Warning (test-scale-binned.R:48:3): binned scales can use limits and transformations simultaneously (#6144)
The `trans` argument of `binned_scale()` is deprecated as of ggplot2 3.5.0.
i Please use the `transform` argument instead.
Backtrace:
    ▆
 1. └─ggplot2::scale_x_binned(limits = function(x) x + 1, trans = transform_log10()) at test-scale-binned.R:48:3
 2.   └─ggplot2::binned_scale(...) at ggplot2/R/scale-binned.R:34:3
 3.     └─ggplot2:::deprecate_soft0("3.5.0", "binned_scale(trans)", "binned_scale(transform)") at ggplot2/R/scale-.R:307:5
─────────────────────────────────────────────────────────────────────────────────────────────────────────────

══ Results ══════════════════════════════════════════════════════════════════════════════════════════════════
[ FAIL 0 | WARN 1 | SKIP 0 | PASS 15 ]

Copy link
Collaborator

@teunbrand teunbrand left a comment

Choose a reason for hiding this comment

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

Looks great! Previously I tried to sneak in a fix for this too in #6007, but this is cleaner.

@yutannihilation
Copy link
Member Author

Oh, I was wondering if you already addressed this, but I was too lazy to check the existing pull requests, sorry... Anyway, I'm merging this. Thanks for your review!

@yutannihilation yutannihilation merged commit cf7ec18 into tidyverse:main Nov 26, 2024
13 checks passed
@yutannihilation yutannihilation deleted the fix/transform-arg-in-test branch November 26, 2024 07:21
@teunbrand
Copy link
Collaborator

but I was too lazy to check the existing pull requests

No worries, I understand: they've been accummulating a little bit 😅

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