-
Notifications
You must be signed in to change notification settings - Fork 11
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
WISH: _R_CHECK_LENGTH_1_LOGIC2_=package:_R_CHECK_PACKAGE_NAME_,abort,verbose #71
Comments
Makes sense to me, especially since we already set BTW, it seems that this does not work interactively:
Is it only supposed to work in the context of |
Yes, the So, use Sys.setenv(`_R_CHECK_LENGTH_1_LOGIC2_`="true")
c(TRUE, TRUE) && TRUE
Error in c(TRUE, TRUE) && TRUE :
'length(x) = 2 > 1' in coercion to 'logical(1)'
Sys.setenv(`_R_CHECK_LENGTH_1_CONDITION_`="true")
if (c(TRUE, FALSE)) "yes" else "no"
Error in if (c(TRUE, FALSE)) "yes" else "no" :
the condition has length > 1 |
Ok I see. Thanks for the clarification. Done in c28f34d |
Awesome. Enabling this on Bioc, in addition to CRAN, will speed up the process of being able to make this bug an error by default in R. |
Hopefully. But when you realize that base R itself still contains numerous misuses of |
@HenrikBengtsson @lshep This new setting is currently causing
So we might disable this for now (there are other more urgent problems in BioC devel that we want to focus on at the moment). |
@hpages up to you. We knew this would break a lot of packages and to me the sooner it can get cleaned up the better. They will all have to deal with the errors eventually whether we implemented it now, 3 months from now, 6 months from now... especially if the overall plan is to make this a default in R. |
Thanks. For the record: 72 out of ~1823 gives that 3.9% of the packages (still) have this bug. (That is in line with what I've found when running 100's of revdep checks in the past). I think there is a risk that one of these PS. I've submitted quite a few PR bug fixes on this and the fixes have often been quick and straightforward when the bugs where harmless - only a few required deep brain cycles from the maintainers. |
Also, the sooner we can get all Bioconductor and CRAN packages to pass their own tests with |
Disabled for now (commit 88bfa1f). Will enable this again at some point after the holidays. Keeping the issue open in the mean time. H. |
I have re-enabled this on our devel builders yesterday 473d26b and it should be reflected in today or tomorrow's report. I will try and send an email to packages that are affected by this setting Monday and probably post an announcement on the bioc-devel mailing list today (hopefully some will fix before monday and less to contact) |
It's been ~6 weeks since you enabled the |
I sent out private emails to all failing Bioconductor packages this week so it might take another week or two to have a significant change since many didn't acknowledge my first group email but many responded to this one ... I'm hoping the numbers improved and I'm hoping even more so in the next two weeks or so ... |
@HenrikBengtsson We just realized that we miss catching some ERROR's when using |
I think setting environment variable $ export _R_CHECK_LENGTH_1_LOGIC2_="package:_R_CHECK_PACKAGE_NAME_,abort,verbose"
$ export _R_CHECK_LENGTH_1_CONDITION_="package:_R_CHECK_PACKAGE_NAME_,abort,verbose"
$ _R_CHECK_PACKAGE_NAME=foo R CMD build foo |
Thanks Henrik. @lshep That works but that means that if we want to use this solution in the context of the SPB or the nightly builds then we need to modify the exact command that we use for the BUILD step (we need to prepend it with Unfortunately at this point I don't see an easy way to use The 2 alternatives I can think of are:
Just putting them here for the record but nothing satisfying. What other options do we have? |
Please consider adding:
to
R_env_vars.{bat,sh}
so that bugs like:are caught.
The text was updated successfully, but these errors were encountered: