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

lintr-bot does not seem to respect .lintr file #345

Closed
javierluraschi opened this issue Aug 24, 2018 · 4 comments
Closed

lintr-bot does not seem to respect .lintr file #345

javierluraschi opened this issue Aug 24, 2018 · 4 comments
Labels
bug an unexpected problem or unintended behavior

Comments

@javierluraschi
Copy link

See https://github.com/rstudio/mlflow/blob/master/R/mlflow/.lintr changing to line-width to 120 but comments in PR point to 80:

https://github.com/rstudio/mlflow/pull/43

@alexeckert
Copy link

I'm experiencing the same problem. The rules defined in a .lintr file will be respected when calling lint_package from RStudio or when calling it locally using Rscript -e "lintr::lint_package()". In travis however all rules are used and .lintr won't be used.

@strboul
Copy link

strboul commented Dec 16, 2018

I also experience the same problem.

@russHyde russHyde added the bug an unexpected problem or unintended behavior label Jan 12, 2019
@russHyde
Copy link
Collaborator

@javierluraschi I noted that you are using a testthat linting test. Could you confirm if you get the same problem if you remove the testthat call to linting and add an after_success call to Rscript -e 'lintr::lint_package()' as described here https://github.com/jimhester/lintr#non-failing-lints

@jimhester
Copy link
Member

I think this is a problem with the working directory when the tests are run, I think I would recommend not using lintr from within your tests.

dschlaep added a commit to DrylandEcology/rSOILWAT2 that referenced this issue Oct 15, 2019
we are currently using `lintr` in `testthat` tests -- this is apparently not intended usage (see https://github.com/jimhester/lintr#continuous-integration) and thus our setup does not respect `.lintr` settings (r-lib/lintr#345)

--> keep our current setup and turn of verbose `lintr-bot`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug an unexpected problem or unintended behavior
Projects
None yet
Development

No branches or pull requests

5 participants