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

Add compatibility for RuboCop v1.38.0 and above #5

Merged
merged 1 commit into from Jan 9, 2023

Conversation

leoarnold
Copy link
Contributor

Due to rubocop/rubocop#10987 we need to set ProcessedSource#config and ProcessedSource#registry.

Not doing so caused Lint/MissingCopEnableDirective and Lint/RedundantCopDisableDirective cops to crash.

Due to rubocop/rubocop#10987 we need to
set `ProcessedSource#config` and `ProcessedSource#registry`.

Not doing so caused `Lint/MissingCopEnableDirective` and
`Lint/RedundantCopDisableDirective` cops to crash.
leoarnold added a commit to leoarnold/templatecop that referenced this pull request Jan 9, 2023
When a cop raises an exception, RuboCop will swallow it and tell
you to use debug mode if you want to see the backtrace.

I needed to add this in order to be able to debug the problems
which lead to PR r7kamura#5.
leoarnold added a commit to leoarnold/templatecop that referenced this pull request Jan 9, 2023
When a cop raises an exception, RuboCop will swallow it and tell
you to use debug mode if you want to see the backtrace.

I needed to add this in order to be able to debug the problems
which lead to PR r7kamura#5.
Copy link
Owner

@r7kamura r7kamura left a comment

Choose a reason for hiding this comment

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

Thanks @leoarnold, I can't accept the changes about Gemfile.lock, but I would like to merge the other points.

@@ -6,6 +6,7 @@
/pkg/
/spec/reports/
/tmp/
Gemfile.lock
Copy link
Owner

Choose a reason for hiding this comment

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

This change is unacceptable.
Bundler recommends in its official documentation that Gemfile.lock be managed by Git, and in fact the rubocop-rails gem and rubocop-rspec gem have various problems by not managing Gemfile.lock with Git. If you want to make sure that it works with the latest version of RuboCop without any problems, I think it would be better to set up a separate workflow to check it.

r7kamura added a commit that referenced this pull request Jan 9, 2023
@r7kamura r7kamura merged commit 8d00fd0 into r7kamura:main Jan 9, 2023
r7kamura pushed a commit that referenced this pull request Jan 9, 2023
When a cop raises an exception, RuboCop will swallow it and tell
you to use debug mode if you want to see the backtrace.

I needed to add this in order to be able to debug the problems
which lead to PR #5.
@leoarnold leoarnold deleted the leoarnold/cop-registry branch January 9, 2023 22:47
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.

None yet

2 participants