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

Error occured while Layout/HashAlignment inspects #9868

Closed
fpietka opened this issue Jun 11, 2021 · 1 comment
Closed

Error occured while Layout/HashAlignment inspects #9868

fpietka opened this issue Jun 11, 2021 · 1 comment

Comments

@fpietka
Copy link

fpietka commented Jun 11, 2021

Expected behavior

I expect to rubocop errors while running it.

Actual behavior

When running rubocop I have lot of this error:

An error occurred while Layout/HashAlignment cop was inspecting [...]
Errors are usually caused by RuboCop bugs.
Please, report your problems to RuboCop's issue tracker.
https://github.com/rubocop/rubocop/issues

Mention the following information in the issue report:
1.16.1 (using Parser 3.0.1.1, rubocop-ast 1.7.0, running on ruby 2.7.3 x86_64-darwin19)

When running in debug mode I have additional information:

An error occurred while Layout/HashAlignment cop was inspecting [...]
undefined method `loc' for nil:NilClass

Steps to reproduce the problem

We have this error since trying to bump rubocop-rails from 2.9.1 to 2.10.1.
I think Layout/HashAlignment just need to be enabled.

RuboCop version

1.16.1 (using Parser 3.0.1.1, rubocop-ast 1.7.0, running on ruby 2.7.3 x86_64-darwin19)
  - rubocop-performance 1.9.1
  - rubocop-rails 2.10.1
  - rubocop-rake 0.5.1
  - rubocop-rspec 2.3.0
@koic koic added the duplicate label Jun 11, 2021
@koic
Copy link
Member

koic commented Jun 11, 2021

The issue is dup with #9861 and resolved by #9862.

@koic koic closed this as completed Jun 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants