add stats:: in front of stats functions that were not explicitly imported#6793
add stats:: in front of stats functions that were not explicitly imported#6793teunbrand merged 2 commits intotidyverse:mainfrom
Conversation
|
hi maintainers, maybe @teunbrand? Could you help allow this merge. the check failures seems unrelated to this PR, though i'm not sure... thank you. |
|
Did the previous PR replace |
|
@Breeze-Hu is right. Instead of prefixing the |
|
thanks guys, but i don't think it's a simple replace for those remaining stats::ave to vec_ave These remaining stats::ave has multiple grouping variables, but the vec_ave only supports 1 grouping variable Lines 152 to 154 in 1052371 Lines 938 to 947 in 1052371 I think this PR is unrelated the to stats::ave -> vec_ave change from #6698. Any way we can allow this PR through without being blocked by these unrelated changes? Ideally there should be a continuation of #6698 separately, assuming that PR simply missed these stats::ave, again probably because these weren't prefixed with stats::. This forgetting of prefixing stats:: just keeps creeping up year after year, to the point where perhaps it's better to just import all of stats, or configure testthat to run all test suite without stats imported at R startup. But that's above my pay grade, probably @teunbrand Lines 4 to 10 in 1052371 |
|
I've added the
Yeah it just part of the general fight against entropy. I'd not be happy to wholesale import stats, but it might be fine if somebody wants to contribute a separate PR that creates a unit test to guard against this. |
teunbrand
left a comment
There was a problem hiding this comment.
Thank you for the contribution!
…rted (#6793) * add stats:: in front of stats functions that were not explicitly imported * use `vec_ave()`
This problem of not explicitly putting
stats::in front of stats package functions was previously documented in #5186. Previously the fix was done in eg #5514This PR is similar, cleaning up more calls to stats functions that do not have
stats::in front of them.