Closed EmilRehnberg closed 4 years ago
Under what circumstances? The package passes all cran checks and unit tests without warnings
on 8.11
the tests in tests/testthat/test-tbats.R
gives me 6 warnings.
Looking through my options, I got warnPartialMatchDollar = TRUE
.
Do you think it's reasonable to have the forecast
package pass tests with the warnPartialMatch
flags set to TRUE
?
the option flags are
warnPartialMatchArgs
warnPartialMatchAttr
warnPartialMatchDollar
There are no warnings on my computer, or on CRAN, or on Travis. See https://travis-ci.org/robjhyndman/forecast/jobs/648131680 or https://cran.r-project.org/web/checks/check_results_forecast.html. So whatever is going on, I suspect it has something to do with your packages or settings.
With these optional warnings set I get many partial matches throughout the package. For test-tbats.R, I get:
─────────────────────────────────────────────────────────────────────────────────
✓ | 21 6 1 | Tests on tbats() functions [12.9 s]
─────────────────────────────────────────────────────────────────────────────────
test-tbats.R:37: warning: Test tbats() and forecasts
partial match of 'gamma.one.v' to 'gamma.one.values'
test-tbats.R:37: warning: Test tbats() and forecasts
partial match of 'gamma.two.v' to 'gamma.two.values'
test-tbats.R:45: warning: Test tbats() and forecasts
partial match of 'gamma.one.v' to 'gamma.one.values'
test-tbats.R:45: warning: Test tbats() and forecasts
partial match of 'gamma.two.v' to 'gamma.two.values'
test-tbats.R:45: warning: Test tbats() and forecasts
partial match of 'gamma.one.v' to 'gamma.one.values'
test-tbats.R:45: warning: Test tbats() and forecasts
partial match of 'gamma.two.v' to 'gamma.two.values'
Avoiding partial matching is the right thing to do, and so if you're interested in making a PR for this I'd happly accept it.
@mitchelloharawild thanks for that! I'll submit something in due time.
Hi @mitchelloharawild Looks like you started on this, do you want to continue? I also started adding some fixes.
Happy for you to continue with the fixes, I wanted to add the partial matches to the check requirements. From the check warnings it looks like there are a lot of partial matching, so of course there is no pressure for you to fix all of them. Submit a PR fixing however many partial matches you'd like and then I'll fix the rest.
I think the merged code closes this issue.
Hi! This package gives plenty warnings regarding partial matches (while accessing names).
Is it ok if I take a stab at fixing this and submit a PR?